News for hackers. Stuff that matters.
Re:Hello Yarn 2, Goodbye node_modules by idoubtit on Tuesday August 10, 2021 @05:34AM (#28126781)
No, yarn and npm don't have the same CLI API. For instance, the most basic command that adds a dependency :

npm install [package]

yarn add [package]

Even the options for this command are different (--save-dev vs --dev). In fact, the situation is even more confusing, since `yarn install` exists but does not accept parameters:

     yarn install
    [1/4] Resolving packages...
    success Already up-to-date.

     yarn install something
    error `install` has been replaced with `add` to add new dependencies.
    Run "yarn add something" instead.

There are no comments on this comment yet.