Created
September 22, 2016 21:05
-
-
Save theskillwithin/57c3ae313aee1d4810d8a0d2b7e47818 to your computer and use it in GitHub Desktop.
npm-scripts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "heartcup", | |
"version": "1.2.0", | |
"description": "hearcup.", | |
"keywords": [ | |
"npm", | |
"scripts", | |
"npm scripts", | |
"watch", | |
"minify", | |
"compress" | |
], | |
"eslintConfig": { | |
"env": { | |
"browser": true, | |
"node": true, | |
"jquery": true | |
} | |
}, | |
"scripts": { | |
"clean": "rm -f dist/{assets/css/*,js/*,assets/img/*}", | |
"autoprefixer": "postcss -u autoprefixer -r dist/assets/css/*", | |
"scss": "node-sass --output-style compressed -o dist/assets/css src/assets/css", | |
"lint": "eslint src/assets/js", | |
"uglify": "mkdir -p dist/assets/js && uglifyjs src/assets/js/*.js -m -o dist/assets/js/app.js && uglifyjs src/assets/js/*.js -m -c -o dist/assets/js/app.min.js", | |
"imagemin": "imagemin src/assets/img/* -o dist/assets/img", | |
"icons": "svgo -f src/assets/img/icons && mkdir -p dist/assets/img && svg-sprite-generate -d src/assets/img/icons -o dist/assets/img/icons.svg", | |
"serve": "browser-sync start --server './dist' --files 'dist/assets/css/*.css, dist/assets/js/*.js, **/*.html, !node_modules/**/*.html'", | |
"build:css": "npm run scss && npm run autoprefixer", | |
"build:js": "npm run lint && npm run uglify", | |
"build:images": "npm run imagemin", | |
"build:all": "npm run build:css && npm run build:js && npm run build:images", | |
"watch:css": "onchange \"src/assets/css\" -- npm run build:css", | |
"watch:js": "onchange \"src/assets/js\" -- npm run build:js", | |
"watch:images": "onchange \"src/assets/img\" -- npm run build:images", | |
"watch:all": "npm-run-all -p serve watch:css watch:js watch:images", | |
"postinstall": "npm run build:all && npm run watch:all" | |
}, | |
"devDependencies": { | |
"autoprefixer": "^6.3.6", | |
"browser-sync": "^2.12.8", | |
"eslint": "^3.5.0", | |
"eslint-config-standard": "^6.0.1", | |
"eslint-plugin-promise": "^2.0.1", | |
"eslint-plugin-standard": "^2.0.0", | |
"imagemin-cli": "^3.0.0", | |
"node-sass": "^3.7.0", | |
"npm-run-all": "^3.1.0", | |
"onchange": "^3.0.2", | |
"postcss-cli": "^2.5.2", | |
"pug": "^2.0.0-beta6", | |
"svg-sprite-generator": "0.0.7", | |
"svgo": "^0.7.0", | |
"uglify-js": "^2.6.2" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment