Skip to content

Latest commit

 

History

History
executable file
·
73 lines (49 loc) · 2.7 KB

CONTRIBUTING.md

File metadata and controls

executable file
·
73 lines (49 loc) · 2.7 KB

Contributing to jqfactory

  • Take care to maintain the existing coding style.
  • Add Jasmine unit tests for any new or changed functionality.
  • Lint and test your code using grunt.

If you plan to contribute to jqfactory in the future, keep in mind that you should make sure your code passes the Grunt checks. This requires having a complete build environment as detailed below.

After you have verified your code, send a pull request to the jqfactory dev branch. After you send a pull request, you will hear back from me shortly after I review your code.

You'll find source code in the 'src' subdirectory.

Unit Tests

All unit tests are written using the Jasmine Framework.
See the linked pages for a great introduction.

Setting up the jqfactory build environment

Note that you don't actually need to do a build to use jqfactory... you can just uses the JS code as-is. These instructions exist for developers and anyone who wants to delve into the code.

If you just want to use jqfactory, then visit the jqfactory ReadMe on GitHub.

Developer tools

SelectBoxIt uses the following development tools:

  • Node.js: For package management and builds.

  • Grunt: to run the build script.

  • Jasmine: unit testing framework.

  • PhantomJS: headless WebKit browser for testing.

Setting up the developement environment

  1. Install Node.js. Luckily the Node web site makes this fairly straightforward, with installers for the major platforms.

  2. Install Grunt as detailed on the [Grunt 'getting started' page]:

       npm install -g grunt-cli
    
  3. Perform the core dependency installations by navigating to the root of your SelectBoxIt source tree and typing the following on the command line:

       npm install
    

Note: If you are on Windows, remember you need to run the grunt command using grunt.cmd.

  1. Install PhantomJS from its home page. This means downloading the appropriate file, uncompressing it, and then copying the phantomjs file to a location in your path. On MacOSX, this looks something like the following after downloading:

       cd /usr/local/bin
       sudo cp ~/Downloads/phantomjs-1.8.1-macosx/bin/phantomjs .
    

That's it! You should now be set up to edit and test jqfactory.

Contributors

Greg Franko - @gfranko

License

Copyright (c) 2013 Greg Franko
Licensed under the MIT license.