Skip to content

Commit

Permalink
update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
radubrehar committed Oct 30, 2024
1 parent aff2d4c commit 06c6cb6
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions www/content/docs/reference/datasource-api/index.page.md
Original file line number Diff line number Diff line change
Expand Up @@ -350,6 +350,33 @@ All the data items passed to this method will be inserted (in the order in the a

</Prop>

<Prop name="updateDataArrayByNodePath" type="({data, nodePath}[]) => Promise">

> Updates the data for the nodes specified by the node paths.
The first parameter should be an array of objects, where each object has a `data` property (the data to update) and a `nodePath` property (the path of the node to update).


```tsx title="Updating an aray of tree nodes"
dataSourceApi.updateDataArrayByNodePath([
{
data: {
fileName: 'Vacation.pdf',
sizeInKB: 1000,
},
nodePath: ['1', '10'],
},
{
data: {
fileName: 'Report.docx',
sizeInKB: 2000,
},
nodePath: ['1', '11'],
},
]);
```

</Prop>

<Prop name="updateDataByNodePath" type="(data: Partial<DATA_TYPE>, nodePath: NodePath) => Promise">

Expand Down

0 comments on commit 06c6cb6

Please sign in to comment.