You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The component does not react to changes to the layout property. I was trying to add and remove plot annotations by changing the layout prop, but the component does not react to the change.
For example, I have a Plotly component whose data and layout properties are bind to this.data and this.layout
I've encountered the same issue. The problem manifests for me when trying to toggle the visibility of a plotly chart legend. Initially I tried to reset only the layout but found that when resizing the browser that the chart was no longer responsive. Forcing the data to reset whenever I reset the layout seems to fix the issue.
The component does not react to changes to the layout property. I was trying to add and remove plot annotations by changing the layout prop, but the component does not react to the change.
For example, I have a Plotly component whose data and layout properties are bind to
this.data
andthis.layout
In a separate method, I tried to remove all annotations from the plot.
However, in order for the change to be reflected in the Plotly component, I have to somehow reload the data prop like so
In the documentation for poltly.js, it mentioned that certain changes to the layout property do require calling
Plotly.react
orPlotly.relayout
The text was updated successfully, but these errors were encountered: