Boilerplate for npm module. Write with ES6.
Just clone this repo and remove .git
folder.
$ git clone [email protected]:Worldremit/npm-boilerplate.git my-new-module-name
$ cd my-new-module-name
$ rm -rf .git
- Open the
package.json
file with your editor and edit the following fields (name, description, repository). - Initialize your git repository
- Install all
devDependencies
$ yarn install
yarn run clean
- Removebin/
directoryyarn test
- Run tests. Tests can be written with ES6. Executes coverage as well.yarn develop
- Watches changes tosrc
and re-transpile code.yarn run lint
- Use'sairbnb
eslint configyarn run build
- Use of babel to transpile ES6 to ES5.yarn run prepublish
- Hook for npm. Build before publish.