README
:hibiscus: React Boilerplate
This is a solid React + Typescript Boilerplate, using Webpack and Babel, with CSS Modules
, SASS
and traditional CSS stylesheets. Supports React-Router and Redux-Toolkit too!
This bolierplate also uses a webapck dashboard provided by FormidableLabs, makes you feel like you work at NASA!
:star2: Features
This boilerplate has a lot of features, some worth mentioning are:
- TypeScript support
- React-Router and Redux Toolkit support
- CSS Modules and SASS support
- React Refresh for Webpack
- Dotenv for Webpack
- ESLint
- Prettier
- Husky with lint-staged
- Webpack Bundle Analyzer
:arrow_heading_down: Installation
If you want to grab this from the web using a package manager like npm
or yarn
, you can get it using the following command(s):
#for yarn users
npm i @sydrawat/react-boilerplate
#for npm users
yarn add @sydrawat/react-boilerplate
:microscope: Usage
If you do not want to install the template using a package manager, you can do so by installing this boilerplate manually from here. Here's how to do so:
- Clone the repository
git clone https://github.com/sydrawat/react-boilerplate.git
- Run the following command
#for yarn users
yarn
#for npm users
npm i
:construction: Development
To run the development server, run the following command:
#for yarn users
yarn start
#for npm users
npm run start
:rocket: Build
- Run the following command to build your project for production:
#for yarn users
yarn build
#for npm users
npm run build
- To see the app in prodution mode, navigate to the
build/
folder that is generated after running the above command. This will serve the production ready app tolocalhost:5000
.
cd build
npx serve