stamen / modestmaps-js

Modest Maps javascript port
http://modestmaps.com
566 stars 152 forks source link

Remove org. from modestmaps #26

Closed tmcw closed 12 years ago

tmcw commented 13 years ago

Okay, this one's up for debate, it's just something that's been bugging me:

The com.modestmaps convention in this naming (which polymaps inherited), seems to be a narrowly Flash (and I suppose Java) idiom, not seem elsewhere in Javascript. Could the library eventually move to simply modestmaps?

RandomEtc commented 13 years ago

I'd consider aliasing it routinely in your app and see what sticks. e.g. I regularly do var MM = com.modestmaps in my app code. Sometimes I even copy all the com.modestmaps members to window with a quick for-in loop.

There needs to be something because e.g. Point, Location, Coordinate, Transformation, Projection and Map are all too generic for Modest Maps to claim in the global namespace. Is MM rare enough?

But yeah it could go away harmlessly - we could even make a com.modestmaps alias of whatever we choose.

tmcw commented 13 years ago

I think MM sounds good. I checked out the source to $.noConflict and it looks unobtrusive enough (albeit reliant on the browser... we'd have to improve that) that we could go for a concise namespace and never totally clobber other tools that take MM.

RandomEtc commented 13 years ago

Underscore has a similar feature, it's a tiny function and just a matter of saving the previous MM before creating your own.

On 5 May 2011 16:56, tmcw reply@reply.github.com wrote:

I think MM sounds good. I checked out the source to $.noConflict and it looks unobtrusive enough (albeit reliant on the browser... we'd have to improve that) that we could go for a concise namespace and never totally clobber other tools that take MM.

Reply to this email directly or view it on GitHub: https://github.com/stamen/modestmaps-js/issues/26#comment_1108905

migurski commented 13 years ago

+1 for MM as well - it's concise and it's what I end up actually using all the time anyway.

tmcw commented 12 years ago

Fixed in a905543d12ee0ea2bfef933d137d0677d0191269