Skip to content

Latest commit

 

History

History
84 lines (55 loc) · 2.81 KB

CONTRIBUTING.md

File metadata and controls

84 lines (55 loc) · 2.81 KB

Contributing

Issues

Feel free to open an issue, or propose a pull request. To prevent duplication, please look at existing issues before posting a new one.

TL;DR

Command Description
npm test Runs test suite once using Mocha. Generates code coverage report in the coverage directory (run open coverage/index.html to view full HTML report).
npm start Runs test once, watch for changes in dev/test files, then re-runs tests automatically when a file changes.
Note: as opposed as npm test, it doesn't generate a code coverage report.
npm run lint Runs ESLint linter.
Note: this is automatically run before the test suite by npm test, but not by npm start.
npm run doc Generates API documentation in esdoc folder.
Note: this is not expected to be run manually since ESDoc hosting service runs it for you.
npm transpile Transpile all files from src directory to dist, using Babel.
Note: this is not expected to be run manually since it is automatically run before NPM packaging (package.json's prepublish script).

Getting started

Step 1. Checkout repository

Prerequisites: you need to have git, node (>=0.10) and npm installed.

git clone https://github.com/cd2bit/a11y-react-redux-router.git

(or your clone's Git URL)

Step 2. Install NPM dependencies

npm install

Step 3. Run tests (run-once mode)

npm test
> a11y-react-redux-router@0.1.0-alpha.2 test /.../a11y-react-redux-router
> npm run lint && rm -rf coverage && istanbul cover _mocha -- specs --recursive --compilers js:babel-register


> a11y-react-redux-router@0.1.0-alpha.2 lint /.../a11y-react-redux-router
> eslint .



  myModule
    ✓ exists
    ✓ is true


  2 passing (21ms)


----------|----------|----------|----------|----------|----------------|
File      |  % Stmts | % Branch |  % Funcs |  % Lines |Uncovered Lines |
----------|----------|----------|----------|----------|----------------|
All files |      100 |      100 |      100 |      100 |                |
 index.js |      100 |      100 |      100 |      100 |                |
----------|----------|----------|----------|----------|----------------|

Step 4. Run tests (TDD mode)

npm start

Coding standards

This project follows Airbnb Javascript Style Guide. It is enforced at build time by ESLint.