Can't use `meteor yarn add bcrypt`?


#1

I tried to use yarn.
I install yarn work fine.
When I run Meteor for the first time, Meteor need:
meteor npm install --save bcrypt, and then I try to meteor yarn add bcryypt.
But don’t work


#2

TL;DR just use meteor npm


Meteor bundles it’s own node and npm install for each version of meteor you have on your machine.

If you want to use yarn with meteor (which is not advised), you will need to install yarn into the path meteor will use for your app in particular.

The easiest way to do this is to:

meteor npm install --global yarn

Now this doesn’t install it globally for your system, but globally for that version of meteor. So if you have other apps running different versions of meteor, or when you update meteor, you will need to run that again.

The alternative option is to install it locally to your project, which is probably overkill


#3

I installed it already meteor npm install --global yarn.
And then meteor yarn add bcrypt, but still don’t work (Meteor need to install meteor npm install --save bcrypt alert)


#4

When I used yarn (before npm 5) I used to make a special case for bcrypt, because yarn never seemed to get the right one in there. I would install it with npm (with -D, but you don’t need that any more in npm 5) and then just run yarn after installing that, to get it into the yarn file.

But really, it’s easier at this point to just use npm. Is there some reason to use yarn now that npm is deterministic?


#5

why wear adidas when you can wear nikes and impress your friends?