liquor-tree icon indicating copy to clipboard operation
liquor-tree copied to clipboard

On checked finish event?

Open nemanja-ivanis opened this issue 4 years ago • 2 comments

I have a tree with lots of parent->children nodes and i am firing an API call on each check/uncheck. My problem is when i fire an API event and i want to get all checked or unchecked nodes i am getting incorrect values because the checking/unchecking of the nodes wasnt finished before the API call was fired. Is there an event or functionality where i can wait until the checking/unchecking is finished and then call the API?

nemanja-ivanis avatar Dec 13 '19 10:12 nemanja-ivanis

Hi! Can you show a real example on https://codesandbox.io/? Triggering check event working syncronly

amsik avatar Dec 16 '19 08:12 amsik

It is a bit of a complicated issue to replicate, i have managed to resolve it with setting a timeout and calling the API only on the targetNode. If you have any suggestion how it could work otherwise based on the little info i provided it would be welcome. Thanks anyways.

nemanja-ivanis avatar Dec 16 '19 13:12 nemanja-ivanis