A React Quiz component developed by the British Council.
npm install
npm start
open http://localhost:3000
npm test -- --watch
We use Semantic Versioning and bump versions using the npm version
command (see npm docs). We've defined preversion
and postversion
hooks in package.json
.
-
You should only publish the master branch. Make sure to be clear on what kind of version it is (
patch
,minor
ormajor
). Create a new version:npm version patch
This transpiles the source files to ES5 using babel. The version is bumped and committed to both master and in the
dist
branch (which is an orphan branch that only includes the files we want to distribute). You'll be left in thedist
branch. -
Ensure you are in the
dist
branch. Do agit log
to check that the version number is correct. Test that the version works correctly. When you're confident, push to GitHub:git push origin && git push origin --tags
-
Again, make sure you are still in the
dist
branch. Publish to npm:Example:
npm publish ./
-
Go back to master branch and push it.
webpack setup based on React Hot Boilerplate.