-
-
Notifications
You must be signed in to change notification settings - Fork 114
Description
I spent time integrating this library into a codebase and managing data and what updates when was a real PITA. We currently do not have a consistent or sane way to make this happen.
I am pretty unsure about the hub generally. In a larger app like Plotly's frontend where would the hub live exactly? I think we should try and 🔪 it.
Should we replace it with a collection of actions and reducers that people can use in their own apps data flow patterns?
Should we remove editorRevision and plotRevision from the hub (or the whole hub) and also remove the revision props from react-plotly.js and react-plotly.js-editor? Instead we could expect shallow equals checks of props.
In some cases it may be necessary to mutate a giant data array. In that case we could demand that the dataSources object or the plotly.js gd.data object will be "rewrapped" in a new container therefore triggering the correct behavior in a shallow equals check.
The reducers we supply could encode that behaviour.