I have a project that displays about 10 serial charts stacked vertically. Each chart displays live-updating data, so they are often redrawing. If scrolling the page when a redraw happens, the smooth scroll freezes momentarily. This is annoying when graphs are updated often.
After some research, I found that that the reason for the freeze was that amcharts registers global, non-passive listeners on window:DOMMouseScroll and document:mousewheel. I was able to work around the issue by forcing those listeners to register as passive (something similar to https://www.npmjs.com/package/default-passive-events) though this is not a real solution because amcharts' listener requires the use of preventDefault() when mouse-wheel zooming is enabled.
I think a proper solution, if possible, would be for amcharts to register a mousewheel listener only on graphs that have mouse-wheel zooming enabled.
I have a project that displays about 10 serial charts stacked vertically. Each chart displays live-updating data, so they are often redrawing. If scrolling the page when a redraw happens, the smooth scroll freezes momentarily. This is annoying when graphs are updated often.
After some research, I found that that the reason for the freeze was that amcharts registers global, non-passive listeners on window:DOMMouseScroll and document:mousewheel. I was able to work around the issue by forcing those listeners to register as passive (something similar to https://www.npmjs.com/package/default-passive-events) though this is not a real solution because amcharts' listener requires the use of preventDefault() when mouse-wheel zooming is enabled.
I think a proper solution, if possible, would be for amcharts to register a mousewheel listener only on graphs that have mouse-wheel zooming enabled.