catbadger
catbadger

Reputation: 1822

Leaflet.js How Do I only draw visible layers?

I'm using leaflet.js to track a ton of assets. How can I only render the assets (layers) that are in the visible area (bounds)?

Upvotes: 0

Views: 332

Answers (1)

catbadger
catbadger

Reputation: 1822

After getting no help here, I begged for help on IRC. Leaflet does this automatically. Leaflet prunes vector layers, mostly. It also only renders vector features when the viewport changes, or when zoom levels change

Upvotes: 1

Related Questions