finnp / view-geojson

geojson viewer with streaming support
7 stars 0 forks source link

throttle setting view bounding box #3

Open derhuerst opened 3 years ago

derhuerst commented 3 years ago

We're currently re-setting the view bounding box on every item that the client receives from the server:

https://github.com/finnp/view-geojson/blob/ed32c75a3fcadfe86cc6793e831658c0cdbde62e/browser.js#L90-L94

This leads to a "flashing" of ever-changing views. Using lodash's throttle would improve the UX a lot!