mizzao / meteor-sharejs

Meteor smart package for transparently adding ShareJS editors to an app
MIT License
225 stars 53 forks source link

Depend on whatever version of mongodb that Meteor is using #22

Closed mizzao closed 9 years ago

mizzao commented 9 years ago

...instead of having Npm.depends for ourself and always having to update that.

There was a thread about this and MongoInternals; figure out how to make that work and to do anything more advanced if appropriate.

mizzao commented 9 years ago

MongoInternals is currently exported, but what we really need is a way for NPM modules to be able to require('mongodb') and for Meteor to provide that.

Opened meteor/meteor#2759 suggesting a better way to do this.

mitar commented 9 years ago

I think that Meteor is just moving to 2.6, so the npm dependency will probably have to be updated.

mizzao commented 9 years ago

Ok, so I'd really like to just use the NPM mongdb package that Meteor is using, without triggering all this binary build bullshit. Is there any way that I can achieve this?

mitar commented 9 years ago

I do not know. I was just looking around the code but I do not know. They are working on providing access to assets and NPM content, so maybe then we can get absolute path to NPM content of mongodb NPM package and fake node_modules in the right place. But no idea how this would work with isopackages.

mizzao commented 9 years ago

Fixed this by depending on a custom fork of ShareJS that does not do an undeclared require("mongodb"):

https://github.com/mizzao/ShareJS/commit/05b625ea1e7f7f27bd13ba7ed05102b38dd175e5