MrBlenny / react-flow-chart

🌊 A flexible, stateless, declarative flow chart library for react.
https://mrblenny.github.io/react-flow-chart/index.html
MIT License
1.48k stars 306 forks source link

Dynamically Update the Chart State #164

Open akhil97 opened 4 years ago

akhil97 commented 4 years ago

Hi,

I'm using the FlowChartWithState component and I'm setting an initial value from the variable chartSimple given in the example on the Readme page. I tried to update the variable and I can see that the props for the component are updating but the state isn't. Can you please help? I've attached a screenshot of the issue. image

karthiksubramaniam commented 4 years ago

Is your variable is maintained in state? In my case I'm using redux state container, mapping redux state to props and binding to FlowChartWithState.

This didn't worked and I ended up re-mounting component by updating the parent props property to hide and show.