Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
useful scripts section for package.json (npm/webpack/babel/storybook/esdoc/coverage/eslint)
"scripts": {
"---Dev": "---",
"storybook": "start-storybook -p 9001 -c .storybook",
"dev:start": "npm run storybook",
"start": "npm run dev:start",
"---Build": "---",
"clean": "echo 'Cleaning lib folder...\n' && rm -rf ./lib",
"build": "npm run clean && echo 'Building...\n' && babel src --out-dir lib --copy-files --ignore **/__tests__",
"watch": "babel src -w -s inline --out-dir lib --copy-files --ignore **/__tests__",
"-----Tests": "-----",
"lint": "eslint src --ext=jsx --ext=js",
"test": "NODE_ENV=development jest",
"tests": "npm run test",
"test:single": "npm run test",
"test:coverage": "npm run test -- --coverage",
"-----Docs": "-----",
"docs": "npm run docs:storybook",
"docs:es": "esdoc -c .esdocrc && open ./esdoc/index.html",
"docs:storybook": "build-storybook -o ./docs/",
"view:coverage": "npm run test-coverage && open ./coverage/lcov-report/index.html",
"---Git Hooks": "---",
"precommit": "npm run lint:diff",
"prepublish": "npm run build",
"prepush": "npm run lint && npm run test"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment