apneadiving / Google-Maps-for-Rails

Enables easy Google map + overlays creation in Ruby apps
https://apneadiving.github.io/
MIT License
2.27k stars 382 forks source link

customClusterer #423

Closed brlo closed 10 years ago

brlo commented 10 years ago

Hello, I'm trying to use custom clusters such in this tutorial https://github.com/apneadiving/Google-Maps-for-Rails/wiki/Markers#wiki-customize-clusterer-images but I'm getting next error: Uncaught TypeError: Cannot set property 'customClusterer' of undefined Is this old tutorial? Because the links to files are wrong and variables are also absent.

Thanks.

apneadiving commented 10 years ago

this is deprecated for v2, basically, pages for v2 are the one you see in the wiki's home, not more.

the clusterer options must now be passed to the handler:

handler = Gmaps.build('Google', { markers: { clusterer: your_options } } );

its documented in the code: https://github.com/apneadiving/Google-Maps-for-Rails/blob/master/vendor/assets/javascripts/gmaps/objects/handler.coffee#L3

brlo commented 10 years ago

Thank you. The problem solved.