Develop an app using JavaScript and ReactJS that allows you to track multiple counter totals in the browser.
The app should consist of the following. A total counter, the ability to add a counter and the ability to increment and decrement that counter. (See layout for example UI).
Example UI |
---|
You can use the boilerplate provided in the repo, or create your own structure if you prefer.
- Browserify for modularity
- babel for jsx transforms
- Mocha for tests
- Chai for extend assertions
- Sinon stubs, mocks and spies
- Express to serve the application on PORT 5000
Assumes you have node 0.12 installed. We are aware of issues installing on node 4+.
$ npm run setup # install global dependencies, node modules and build production assets
$ npm run build # build assets
$ npm test # run tests
$ npm start # start server on localhost:5000
For convenience the most common React TestUtils methods are exposed globally in the tests. These include:
TestUtils
renderIntoDocument
Simulate
scryByType
findByType
scryByClass
findByClass
scryByTag
findByTag
scryByProp
findByProp
- App should work on latest Chrome and Firefox