istarkov / google-map-clustering-example

clustering example for google-map-react
http://istarkov.github.io/google-map-clustering-example/
200 stars 76 forks source link

Host points-cluster on GitHub? #4

Closed joshburgess closed 8 years ago

joshburgess commented 8 years ago

Can you host your fork of supercluster on GitHub? It appears that the API is different, and it's difficult to guess the changes... There is almost 0 documentation on mapbox's supercluster, and even less on points-cluster.

istarkov commented 8 years ago

It always was on github https://github.com/istarkov/supercluster ;-) I never thought that somebody else will use it so there is a problem with package.json

istarkov commented 8 years ago

Wow https://www.npmjs.com/package/points-cluster 1600+ downloads/month ;-)

joshburgess commented 8 years ago

I've been bouncing around trying to use the original supercluster and your fork. so far, I'm not successful with either of them :[ have had a very difficult time trying to reproduce the same sort of thing you did in this clustering demo.

Can you tell me something? The original supercluster's getClusters function takes an array for the map bounds instead of the bounds object. What is the correct order of the coordinates? I'm able to see that supercluster is generating the clusters in my console, but so far I've been unable to get anything other than an empty array when calling getClusters... :/

joshburgess commented 8 years ago

By the way, what was the bbox search bug in your supercluster fork? When I tried to use your fork, I just kept getting an error related to search.

istarkov commented 8 years ago

Current supercluster uses minX, minY, maxX, maxY order, and it's far away from my fork My issue with it, was the search problem around 180 meridian. https://github.com/istarkov/supercluster/blob/master/src/index.js#L62-L64

My fork works well here https://github.com/istarkov/google-map-clustering-example And in some internal projects, I can't say anything about your search errors without examples.

joshburgess commented 8 years ago

I've got it working now. Sorry for ranting. :laughing: