Real time event when dragging or zooming the plot

I would like to hook data in my webpage to what is displayed on the graph. I am currently using the ‘plotly_relayout’ event but this event only fires at the end of the dragging action, while I want to do some real time feedback.Is there such an event available?
The current alternative I am looking at is to hook on event on mousemove and check the changes of the transform attribute of the .plot element, and then translate these values into the data domain.

1 Like

Not at the moment. I’d recommend trying to bind an event handler to the graph div itself. I can’t guarantee this will perform well though.

Hey @daniel @etienne did you find a good solution for this? Would really appreciate any help, as I am stuck on this for long. Could you also share a code snippet of what you ended up doing?

Did you find any solution?

Binding the mousemove event to the graph div only fires when I move the mouse without dragging. Even adding graphDiv.ondragstart = () => false; didn’t help here.

I need to “link” two plots.

I think I had something similar, but I used Dash and Python…