React Component library for Movio Components.
Install project dependencies and start local server:
$ npm install
$ npm start
View at http://localhost:8080
Generates basic scaffolding for a new component
$ ./bin/generate ComponentName
Script | Description |
---|---|
start |
Starts the Webpack dev server, available at http://localhost:8080 |
test |
Starts Karma for single run test (uses PhantomJS) not for CI |
test:ci |
Starts Karma for single run test (uses PhantomJS) for CI |
test:watch |
Starts Karma with watch |
lint |
Runs ESLint not for CI |
lint:ci |
Runs ESLint for CI |
format |
Fixes linting issues (where applicable) |
lint:style |
Runs Stylelint not for CI |
lint:style:ci |
Runs Stylelint for CI |
check |
Runs tests and linters for CI |
docs |
Generates component documentation |
serve:docs |
Serves the documentation at http://localhost:8081 |
serve:coverage |
Serves the coverage report at http://localhost:8082 |
Run unit tests using:
# Single run
$ npm test
# Auto watch
$ npm run test:watch
Coverage reports are available using:
# Served at http://localhost:8082
$ npm run serve:coverage