Describe the bug
I'm retrieving a cron from a database, and want to update the value of the cron to the value I get from the database.
When the response is retrieved from the database, the values of the component are not updated to the value of the new 'cron' prop.
Steps to reproduce
Demo here: https://codesandbox.io/s/material-ui-cron-stable-forked-5r89pd
Render component with:
const CronGenerator = (props) => {
const [cron, setCron] = useState("30 9 * * 1")
setTimeout(() => setCron("* * * * *"), 2000)
return (
<SchedulerRoot cron={cron}
setCron={updateCron}
setCronError={() => {}}
isAdmin={true}
/>
);
}
The component does not refresh to reflect the new value. I've included a picture to show that the props in React Component profiler are different to that actually displayed.

Note that I'm having to use the SchedulerRoot component due to an error when rendering just the <Scheduler /> component (image of the error below). However, note that in the demo linked at the top of this post, the same problem exists.

Solution (optional)
Additional context (optional)
Describe the bug
I'm retrieving a cron from a database, and want to update the value of the cron to the value I get from the database.
When the response is retrieved from the database, the values of the component are not updated to the value of the new 'cron' prop.
Steps to reproduce
Demo here: https://codesandbox.io/s/material-ui-cron-stable-forked-5r89pd
Render component with:
The component does not refresh to reflect the new value. I've included a picture to show that the props in React Component profiler are different to that actually displayed.
Note that I'm having to use the SchedulerRoot component due to an error when rendering just the
<Scheduler />component (image of the error below). However, note that in the demo linked at the top of this post, the same problem exists.Solution (optional)
Additional context (optional)