mstahv / v-leaflet

Leaflet add-on for Vaadin
Other
43 stars 38 forks source link

Consider changing naming convention? #52

Open mstahv opened 10 years ago

mstahv commented 10 years ago

Should the Vaadin API have non prefixed class names and GWT API be G prefixed?

I guess most users are using the Vaadin API, so it should be considered first class citizen. If nobody disagrees, we could make the change in next larger release. To keep backwards compatibility, aliases with L prefix for relevant layers could be kept for a short time.

Opinions?

octavm commented 8 years ago

I've created a vaadin addon for V-Leaflet of Leaflet.RotatedMarker plugin by Benjamin Becquet (https://github.com/bbecquet/Leaflet.RotatedMarker) The addon is on my github page (https://github.com/octavm/v-leaflet-rotatedmarker-parent) Would it be worth it adding it to vaadin directory, maybe it will help other V-Leaflet users ?

mstahv commented 8 years ago

Sure! Just build the zip files and upload them to https://vaadin.com/directory

If your face some issues with the process, let me know, maybe I can help.

mstahv commented 8 years ago

Congrats, your first Vaadin add-on appears to be out! I think you should also publish a version of the g-leaflet-rotatedmarker module to make it really functional? I didn't try it but just guessed based on the github project structure.

octavm commented 8 years ago

Thanks for the suggestion. Done!

octavm commented 8 years ago

Regarding your naming convention question, if I may suggest, I think the g-leaflet classes should be named LMarker, LTileLayer, etc to match with Leaflet js API and the v-leaflet classes should just be named Marker, TileLayer, etc.

mstahv commented 8 years ago

Agreed, I'll try to do the refactoring at some point before the final 1.0 release. I guess could leave deprecated LMarker/LMap/... (extends Marker) classes still to v-leaflet for backward compatibility, at least for couple of releases. In GWT wrapper we could do the same as well, but it is not that essential there, just affects extensions like your new rotated marker add-on.

Let me know if you want to take care of this refactoring.