WaffleJS, 2017-09-06
Private package hosting: $7/user/month
https://www.npmjs.com/features
to learn more
5 fast facts about npm 5
npm i npm -g
5 fast facts about npm 5
package-lock.json
5 fast facts about npm 5
5 fast facts about npm 5
5 fast facts about npm 5
bonus fact
npm init
> npm install -g cat-fact
> cat-fact
The biggest wildcat today is the Siberian Tiger
Old and busted:
> npx cat-fact
A cat has 230 bones in its body
New hotness:
> npx create-react-app
> npm start
npx -p yo -p generator-karma -p generator-angular -- yo angular
What?
Who?
npx -p yo -p generator-karma -p generator-angular -- yo angular
pkg1
pkg2
pkg3
npx -p yo -p generator-karma -p generator-angular -- yo angular
args
npx vue-cli init pwa myapp
cd ./myapp
npm install
npm run dev
or
npx vue-cli init pwa myapp && cd ./myapp && npm install && npm run dev
npx ember-cli new foo
cd ./foo
npx ember-cli serve
npx -p yo -p generator-node -- yo node
npx serve
npm install --save-dev grunt
npm install -D grunt
Exclude dev dependencies in production:
npm install --production
(and your dev dependencies closer)
npx grunt
Just as fast as a global install!
npx npm-check -u
updates within semver ranges
asks you if you want breaking changes too
Shout out to @mikesherov for his work on this!
These slides:
Come find me for stickers or questions!