Node.js

up:: JavaScript Node.js is an asynchronous event-driven JavaScript runtime.

NPM is a package manager for Node.js packages

Alternatives

  • pnpm: faster and more efficient than npm or yarn
    • pnpm is used by Vue fyi
  • yarn is also pretty fast
    • yarn is used by Nuxt

Installing modules

--save

This is the default. If your are not using -g (for global install), the package is installed with --save.

--dev

Warning

These packages will not be run when installing for production. They are only used in the development stage (eg. linters).

What I don’t really understand about this is that TailwindCSS recommends installation as a DevDependency. Wouldn’t you want it in production? So is Nuxt. It seems like this is due to some magic that Nuxt does under the hood. Apparently it doesn’t matter if you add packages in devDependencies or not. Nuxt takes care of including the relevant packages.