Gives you a minimal setup to get started with React and Webpack 5. Also comes with linting, formatting and a test setup, plus a Github Action for continuous integration.
- Make sure to have Node.js and nvm installed.
- Create a
.env
file in the root folder.-
Populate it with the process variables of your choosing, example:
NODE_ENV=development FOO=bar
-
$ git clone https://github.com/perjo927/react-webpack5-starter.git
$ cd react-webpack5-starter
$ nvm use
$ npm ci
$ npm run build:dev
$ npm run start
$ npm run build:prod
Requires a previous build.
$ npm run demo
$ npm run bundle:analyze:dev
$ npm run bundle:analyze:prod
$ npm run test
$ npm run test:watch
Per Jonsson