plotly / plotly.js

Open-source JavaScript charting library behind Plotly and Dash
https://plotly.com/javascript/
MIT License
17.02k stars 1.86k forks source link

Plotly.react doesn't transition correctly when only annotations are changed #4839

Open aatishb opened 4 years ago

aatishb commented 4 years ago

Here's an example where I'm attempting to transition to a plot with added annotations using Plotly.react. Notice if I update just the layout and not the data, the graph won't update.

Example 1

However if I remove the transition in Example 1, the graph will update correctly.

And if I update the data and the layout together, then also the graph will transition correctly.

Example 2

I have been running into some difficulties with annotations moving around erratically when I try to transition between layouts using Plotly.react, and in trying to debug that noticed the above. This seems to me like a bug related to transitions.

archmoj commented 4 years ago

@aatishb thanks for reporting.