Closed kkweon closed 6 years ago
"scripts": { "build:app": "webpack -p", "clean": "rm -rf node_modules", "webpack": "webpack -p" }
Instead of npm run clean, I wish I could run npx clean
npm run clean
npx clean
In case of duplicates, "scripts" will always override.
"scripts"
Therefore,
npx webpack
will check if webpack is already registered in "scripts"
webpack
If so, it is same as
npm run webpack
which will run ./node_modules/.bin/webpack -p
./node_modules/.bin/webpack -p
npm run
npx
yarn already supports this. I can just run yarn clean yarn build:app
yarn
yarn clean
yarn build:app
Can we have this please? I'm even willing to send a PR if you agree. 🙏🙏🙏
Ref #107 and #64.
Damn sorry about that. Didnt see the #64.
What I want
Instead of
npm run clean
, I wish I could runnpx clean
In case of duplicates,
"scripts"
will always override.Therefore,
will check if
webpack
is already registered in"scripts"
If so, it is same as
which will run
./node_modules/.bin/webpack -p
What's wrong with
npm run
npx
for consistencyyarn
already supports this. I can just runyarn clean
yarn build:app
Can we have this please? I'm even willing to send a PR if you agree. 🙏🙏🙏