- Clone this repo using:
$ git clone [email protected]:ovasylenko/skillcrucial-react-redux-boilerplate.git- To install dependencies and clean the git repo run:
$ yarn installWe recommend using yarn for installing packages, but you can use npm instead:
$ npm install- Create first build
$ yarn run build:prod-
Copy .env.example file to .env and make the necessary changes there
-
Run project in Dev mode
$ yarn run dev- Redux
- Modern ES6 for using template strings, JSX syntax, object destructuring arrow functions and more
- Babel for old browser support
- SASS/SCSS: make styles greate again, with no tears
- React Router
- Hot Module Replacement for comfortable development
You will write your app in this folder. You will spend most of your time in here.
This folder contains all your components
This directory contains compiled project files
Project environment configs. Webpack uses proper config depending on defined application environment.
By default webpack.development.config.js is used unless you build the application with --config webpack.production.frontend.config.js variable.
yarn installInstalls the dependencies.
yarn run devStarts the development server running on http://localhost:3000 using the webpack.development.config.js with Hot Module Replacement (HMR) (Changes in the application code will be hot-reloaded)
yarn run dev:serverStarts the development server and makes your application accessible at http://localhost:3000.
yarn run cleanRemoves a directory "dist" from a project
yarn build:prodPrepares your app for deployment to production environment (using the webpack.production.frontend.config.js) (does not run tests). Optimizes and minifies all files, piping them to the dist folder.
yarn run testTests your application modern JavaScript Testing Framework - Jest with the unit tests specified in the **/__tests__/*.spec.js files
throughout the application.
yarn run test:watchWatches changes to your application and re-runs tests whenever a file changes.
yarn run coverageGenerates test coverage.
It’s also possible to leave out the run in this command, each script can be executed with its name, e.g: yarn test:watch yarn test:coverage
yarn run lintWill analyse your code for potential errors. Will check both: ./client/**/**.js and ./server/**/**.js files.
Code linting is a type of static analysis that is frequently used to find problematic patterns or code that doesn’t adhere to certain style guidelines.
yarn run lint:serverWill analyse only server/**/**.js files