I was wondering why the child component with the changed value is not getting rendered here. Isn’t it a good idea to have a child handle its own changes or better to have the controller in the parent? This is the Child TodoItem As you can see the state is changed with handleChange() but this does not fire the render.
Tag: setstate
Should I use setState conditional updates in componentDidUpdate in React 16?
I’m using React 16 and need to call a conditional setState inside componentDidUpdate. setState is executed asynchronously. So, usually, if I need to use state to compute my next state I should use updater function as an argument to setState. React 16 added a possibility to cancel a setState update by returning null from setState. So, should I use updater