I have an application using OpenLayers 6 where I am listening to
When the user zooms with the scroll wheel on the mouse, my handler gets blasted with dozens of events with intermediate zoom levels (between start and end zoom values).
My handler function is compute intensive, and I only want to receive the event with the last and final zoom level.
As a work-around, I have some code that stores the latest event, and then calls the real handler after 500ms. The code is ugly and becoming complex to maintain. Is there a better way to handle this in OpenLayers?