storybook-eol/react-treebeard

its impossible to update treebeard from client side dynamically?

yakirifrah opened this issue · 0 comments

I have some questions
l
I want to achieve this behavior on sideNav tree (add VLAN branches under Interfaces/Routes as children of Interfaces/Routes parent).
@theinterned @marchdoe @orta @arunoda @kazupon @theinterned

image

  1. Once we click on Interfaces/Routes branch we fetch the VLANS list from the server
    Now we want to append vlans as children to Interfaces/Routes (like in the pic above) dynamically.

  2. How can I pass props to component render by NodeViewer, that will be a working alternative to this pseudo implementation: (then we will build the children array dynamically for all the vlans we get and update the tree accordingly)?

pseudo code implementation

`{
name: 'Interfaces/Routes',
icon: logFiles,
component: SystemConfigInterfacesRoutesScreen,
roleAccess: RoleBasedAccessControl.SYSTEM,
omitInAzure: true,
children:[
{
name:'vlan 1',
render: () => <interfacesRoutesView vlanID={'1'} />;
},
{
name:'vlan 2',
render: () => <interfacesRoutesView vlanID={'2'} />;
}
]
},

`

I'm used in version 2.1.0

Thank you,