MusicQuiz
Web based realtime multiplayer quiz. Use your mobile as a controller, up to 8 players.
Install
Make sure you have Node.js and npm installed.
$ git clone https://github.com/simon-johansson/Quizify.git && cd Quizify
$ npm install
Development
To start the express server in development mode and the webpack-dev-server:
$ grunt serve
This enables livereload and hot loading for the frontend code but the express server needs to be restarted when making changes to the backend code, i.e. stop the server and run the above command again.
To run the project in production mode:
$ grunt serve:dist
# or
$ grunt build
$ NODE_ENV=production node server/main.js
This will build and compile the webpack code into the dist/
folder and start the express server with production settings. Good for verifying before deploying.
Tests
To run all tests:
$ npm test
Frontend
To only run the frontend-tests with Karma using PhantomJS:
$ npm run test-frontend
# or
$ grunt test
To watch for file changes and run the frontend tests repeatedly (good for TDD:ing):
$ grunt test:watch
Also possible to grep and isolate specific tests like so:
$ grunt test:watch --grep="Store"
# or a single run
$ grunt test --grep="Store"
Backend
To only run the backend-tests with Mocha:
$ npm run test-backend
To grep and isolate specific tests:
$ npm run test-backend -- --grep="Track"
Continuous Integration
Travis CI is used for continuously running the tests.
Deployment
Heroku is used for hosting. Deployment is done by pusing to the production
branch. This triggers a new build on Heroku (if the tests pass on Travis-CI).
Noteworthy
- Proxy - A proxy is needed in development mode in order to have both the express and the webpack-dev-server running properly, info.
Stack
Font-end
- Webpack
- ES6
- React
- Reflux
- ReactRouter
Back-end
- Node.js
- Express
- Socket.io
Creators
Licese
??