JiriHoffmann / react-native-clusterer

React Native clustering library using C++ Supercluster implementation
MIT License
157 stars 20 forks source link

Flickering when zooming #42

Open NiccoloCase opened 6 months ago

NiccoloCase commented 6 months ago

https://github.com/JiriHoffmann/react-native-clusterer/assets/41541220/f57957ef-602b-4836-b344-202588c0ddd5

I noticed that the markers used for the cluster glitch when zooming in or out. I believe this is due to a change in the cluster id, which therefore forces a re render, also because I cannot therefore take advantage of the benefits of react.memo. Why this strange behavior of the cluster id? and how to avoid the problem?

JiriHoffmann commented 5 months ago

Can you provide a code example where the ids change?