Deferred context added

This commit is contained in:
tugcekucukoglu 2024-02-21 10:31:43 +03:00
parent 9a416252a7
commit 2f353f2c19
44 changed files with 801 additions and 635 deletions

View file

@ -2,13 +2,15 @@
<DocSectionText v-bind="$attrs">
<p>Setting <i>columnResizeMode</i> as <i>expand</i> changes the table width as well.</p>
</DocSectionText>
<div class="card">
<TreeTable :value="nodes" :resizableColumns="true" columnResizeMode="expand" showGridlines :tableProps="{ style: { minWidth: '50rem' } }">
<Column field="name" header="Name" expander></Column>
<Column field="size" header="Size"></Column>
<Column field="type" header="Type"></Column>
</TreeTable>
</div>
<DeferredDemo @load="loadDemoData">
<div class="card">
<TreeTable :value="nodes" :resizableColumns="true" columnResizeMode="expand" showGridlines :tableProps="{ style: { minWidth: '50rem' } }">
<Column field="name" header="Name" expander></Column>
<Column field="size" header="Size"></Column>
<Column field="type" header="Type"></Column>
</TreeTable>
</div>
</DeferredDemo>
<DocSectionCode :code="code" :service="['NodeService']" />
</template>
@ -106,8 +108,10 @@ const nodes = ref();
}
};
},
mounted() {
NodeService.getTreeTableNodes().then((data) => (this.nodes = data));
methods: {
loadDemoData() {
NodeService.getTreeTableNodes().then((data) => (this.nodes = data));
}
}
};
</script>