Welcome to NuclearJS! If you are reading this, it probably means that you are interested in contributing to this awesome open source project. To make the process of contributing more straightforward, we have prepared this guideline for you. To learn more about NuclearJS, check out our new developer website!
First of all, you will want to fork this repo and then clone it locally.
Next, you will need to have the following technologies installed: Node, grunt and all the other dependencies.
- Install Node.
- Install Grunt to run the unit tests.
npm install -g grunt-cli
- Install all the other dependencies by running:
npm install
in the nuclear-js directory.
grunt test
To test using Chrome, run: grunt karma:chrome
To run unit tests in PhantomJS + Coverage run: grunt karma:coverage
Nothing special here. Just write good, clean JavaScript. We've made it easier to check your styling now by using eslint. To get instant feedback on any styling violations, simply run: grunt eslint
Some general rules:
- 2 space indentation (no tabs).
- Prefer
'
over"
. - No semicolons unless necessary.
- Last element in an array should be followed with a comma.
- Always use brackets for functions even if it is a one-liner.
- When in doubt, refer to the source code and follow that styling.
- Make sure that you are using the latest version of NuclearJS.
- Before submitting an issue, try to search around as it may have already been answered or even fixed.
- If you still can not find a valid answer, feel free to open up an issue and we will happy take a look for you.
- Work only in the
src
folder and please DO NOT check in anything in thedist
folder. - Follow the Style Guide. Make sure that there are no lint errors or warnings after running:
grunt eslint
- Squash commits that are very small and redundant.
- Make sure all tests pass after running:
grunt test
- If you are implementing a new feature, be sure to add new tests for that feature.
- Provide us with a detailed description of commits and changes.