Skip to content

Instantly share code, notes, and snippets.

@morrisonbrett morrisonbrett/package.json
Last active Jul 15, 2018

Embed
What would you like to do?
Example of npm script commands used in an Ionic project.
"scripts": {
"clean": "ionic-app-scripts clean",
"build": "npm run ionic:build",
"start": "concurrently \"npm run build:watch\" \"npm run serve\"",
"serve": "lite-server -c=bs-config.json",
"ionic:build": "gulp default && npm run lint && ionic-app-scripts build",
"ionic:serve": "gulp default && npm run lint && ionic-app-scripts serve --sourceMap source-map --iscordovaserve --wwwDir platforms/browser/www/ --buildDir platforms/browser/www/build",
"build-prod-browser": "gulp browser && ionic-app-scripts build browser --wwwDir platforms/browser/www --sourceMap source-map",
"build-dev-browser": "gulp browser && ionic-app-scripts build browser --wwwDir platforms/browser/www --sourceMap source-map --dev",
"build-dev-android": "gulp default && cordova build android --debug",
"build-prod-android": "gulp default && cordova build android --release",
"build-dev-ios": "gulp default && cordova build ios --debug",
"build-prod-ios": "gulp default && cordova build ios --release",
"watch": "gulp default && ionic-app-scripts watch --sourceMap source-map",
"test": "karma start ./test-config/karma.conf.js --single-run || true",
"test:watch": "karma start ./test-config/karma.conf.js || true",
"test:coverage": "karma start ./test-config/karma.conf.js --coverage --single-run || true",
"test:coverage:watch": "karma start ./test-config/karma.conf.js --coverage || true",
"lint": "tsfmt -r && tslint -p tsconfig-lint.json"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.