I’m on 1.4 and haven’t been adding npm packages with “meteor npm install”. Does it matter?
It doesn’t matter if the npm version you have installed locally is the same as the one bundled with meteor.
You can compare the two versions:
meteor npm -v and
Some versions of npm install modules with a different folder structure than others, so it might make a difference - especially if you use both.
It will cause trouble if your local version of node is different to meteor’s
and you have npm packages that build native extensions e.g.
Personally, I’ve been using yarn instead of npm and just have to run
meteor npm rebuild node-sass sometimes.
So when starting a new project should I go with ‘npm install’ or ‘meteor npm install’? Why even bother with the meteor version of node if it’s older than npm?
If a package has native extensions like
bcrypt, then for it to work with meteor you have to install it with the same version of node that meteor uses.
The easy way to do this is by running
meteor npm install. There’s no good reason for you to not do this every time.
The node version when you compile native extensions while installing has to exactly match the one you run. Meteor has a fixed version of node for each release so that the whole platform can be more stable, therefore you need to compile the native extensions for the version of Node used by Meteor.
In 1.4.2, you’ll be able to
meteor yarn install things!
Makes sense. Thanks guys!
no way really? That’s awesome! Who doesn’t love yarn
@sashko so with React, GraphQL and Yarn you have officially became the open source division of Facebook?
Facebook is building some great stuff which also aligns with our own philosophy - for example, yarn brings to npm a lot of the same stuff that the meteor package system has.
Yeah I moved from Blaze to React recently and WOW. The clarity of thought I have about my apps now. It’s unreal. Keep going in the direction you guys are moving, it’s a good one!
You should check out Vue.
@aadams, where do you get all these animated GIF’s ? Really cool and a nifty way to attract attention to your post (until every one else does that).
Is your big-fin-gifs hiring?