Required software:
node.js(orio.js) is installed (better 0.11.x or newer) Install latest node.js usingnpm install -g n; n latestas root/admin usernpmis installed (minimum 2.0, check withnpm --version. Upgrade to newer npm withnpm install -g npmand make sure new npm is inPATHwith higher priority than the old one.mongodbis installed
Highly recommended:
boweris installed (runnpm install -g boweras admin)gulpis installed (runnpm install -g gulpas admin)
Optional:
karma is installed (runnpm install -g karma` as admin)protractoris installed (runnpm install -g protractoras admin)chromeandfirefox(optional) are installeddockeranddocker-compose. Installation instructions - Ubuntu, Windows,
To run this project from terminal run the following command:
npm install
npm start
OR if docker and docker-compose are installed (better suited for production usage):
docker build -t sochka/wdc .
docker-compose up
Intellij idea project has preconfigured run configurations.
To generate API documentation run gulp docs
Open docs/index.html to view documentation in the browser.
If you want to debug javascript code in Intellij Idea - set your breakpoints in .tmp/public,
not in assets/.
Otherwise the debugger won't stop at your breakpoints
- MOST IMPORTANT: follow the existing code style
- Make sensible variable names
- Don't use
git pull, usegit pull --rebaseorgit up(git plugin) instead. You can rungit config branch.master.rebase trueto makegit pullbehave likegit pull --rebaseon project basis. - Use commit names in format
[SCOPE] explanationwhereSCOPEis a feature, subproject or component. Examples:- [build] Change gulp task
- [front-end] added new feature
- [hotfix] fixed mistake in previous commit
- [test] added new tests
- [travis] removed module
- [heroku] changed env variables
- Use branches:
masterbranch for stable code synced fromdevelopand bugfixes.developbranch for code in development. Should be regularly merged intomaster- feature-branches for single features development. Should be merged into
develop. - git tags on master branch to mark releases (like
v0.4.3orv1.0)
- git (version control)
- ES6/7 JavaScript (modules, async/await, classes, arrow functions etc...)
- Sails.JS (node.js MVC framework)
- npm (front-end dev. dependencies)
- bower (front-end dependencies)
- jspm (front-end dependencies)
- gulp (front-end task-runner)
- karma (front-end unit-test runner)
- protractor (end-to-end test runner)
- jasmine (test framework)
- angularjs (MVVM front-end framework)
- SystemJS (universal dependency loader)
- LESS (CSS replacement)
- jsdoc (JS documentation engine)
- travis (Continuous Integration)
- heroku (PaaS)
- gravatar (service for centralized user avatar (image) store)
- docker (deployment) (deployment)
The following steps will make your work with Intellij Idea more productive
- Set JavaScript version - EcmaScript 6
- Install TypeScript community stubs for front-end javascript dependencies.
- NodeJS
- gulp
- karma
- LESS
- gitignore (for syntax highlight)
- angularjs
- markdown
- EditorConfig
- EJS
- angularjs batarang
- JetBrains IDE support
