This guide will cover all required steps to start working on React-based frontend part.
If you already have NodeJS installed in your system, you may use it, but be careful since it's version can be outdated.
NodeJS can be installed by several ways, but the most preferred is via NVM. Follow NVM's guide to get it installed.
Run this command to install NodeJS:
nvm install v12
In order to use installed version run:
nvm use
If you want NVM to change node version automatically, please refer to this part of NVM manual
Run this command to install yarn globally:
npm i -g yarn
Now change directory to client
of project's root.
Install required packages:
yarn
After all packages are installed, everything is ready to start development.
Build production bundle:
yarn run build:production
Build development bundle:
yarn run build
Run instant rebuilding based on changes:
yarn run watch
Run webpack dev server:
yarn run server
Run linter (ESLint):
yarn run lint <path_to_file_or_directory>
Run tests:
yarn run test <path_to_test_or_directory>
Please run linter and tests before making a pull request, that will economy other developers' time :)
Most of IDEs have built-in support for ESLint, so please configure them if not already.