react-plotly.js
react-plotly.js copied to clipboard
Is it possible to add some sort of loading spinner to this component ?
I am wondering how can I display a loading spinner while the chart is being rendered. I have a choropleth map with a lot of data and it takes a while for it to finish rendering. I would like to display a spinner until the chart has finished rendering.
Is this possible ?
Have you tried using React Suspense?
I achieved a pretty great loading state by wrapping the chart component in a suspense. The only issue is when there really is TOO much data or a complex to render graph like the 3d chart, in that case suspense still helps, but it does freeze just before rendering