You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 14, 2020. It is now read-only.
I want to use local state to control whether the all the nodes are expanded or collapsed. If I set a local state variable to true and then return that in an an anonymous function assigned to shouldExpandNode() then everything works as expected. If I change this local state variable to false however though the render() lifecycle method is triggered but all the nodes remain expanded.
I'm possibly missing something obvious.
The text was updated successfully, but these errors were encountered:
hi,
<JSONTree
hideRoot={true}
// shouldExpandNode={() => }
getItemString={() => ()}
data={record.description}
/>
About this function shouldExpandNode, how can I use it?
I want JSONTree render the object in expanding.
I want to use local state to control whether the all the nodes are expanded or collapsed. If I set a local state variable to
true
and then return that in an an anonymous function assigned toshouldExpandNode()
then everything works as expected. If I change this local state variable tofalse
however though therender()
lifecycle method is triggered but all the nodes remain expanded.I'm possibly missing something obvious.
The text was updated successfully, but these errors were encountered: