montagejs / collections

This package contains JavaScript implementations of common data structures with idiomatic interfaces.
http://www.collectionsjs.com
Other
2.1k stars 183 forks source link

shim-array - global prototype modification #94

Closed anilanar closed 9 years ago

anilanar commented 10 years ago

https://github.com/kriskowal/q/issues/551

Although I think naming it Array makes the most sense considering the naming convention used by the library, doesn't it break the modular nature of it by modifying a global prototype?

kriskowal commented 10 years ago

Yes, there is certainly a tension here between one kind of modularity and another. Collections and FRB benefit from having a uniform, generic interface across all collections, so in this case, an array can be used as a Set.

kriskowal commented 9 years ago

See #95