Closed
Description
dynamic sizing requires you to explicitly attach a resize handler:
window.onresize = function() { Plotly.Plots.resize(gd); };
This works fine if you pass the plot div element gd
, but (unlike the rest of the API) you cannot use an id 'myGraph'
or you'll get an error:
Uncaught (in promise) TypeError:
Failed to execute 'getComputedStyle' on 'Window': parameter 1 is not of type 'Element'.
cc @VeraZab