The idea was to render only 500 out of 18,000 units when zoomed in enough for this to be valid. If the user scrolls to a different area, we render the CoA of that region. This approach caused flickering. To address this, I shifted to a strategy of rendering visible units first.
This change affects the priority at the edges: CoA are rendered in the order of state > city > municipality, so with this prioritisation, a visible city CoA can overlap a state CoA, even when scrolling make the state CoA visible.
The idea was to render only 500 out of 18,000 units when zoomed in enough for this to be valid. If the user scrolls to a different area, we render the CoA of that region. This approach caused flickering. To address this, I shifted to a strategy of rendering visible units first.
This change affects the priority at the edges: CoA are rendered in the order of state > city > municipality, so with this prioritisation, a visible city CoA can overlap a state CoA, even when scrolling make the state CoA visible.