Boilerplate code with react-router, webpack and babel
If something doesn’t work, please file an issue.
If you have questions or need help, email me at mughalheree@gmail.com.
git clone https://github.com/mughalhere/react-starter-kit cd react-starter-kit npm i npm startThe open http://localhost:8080/ to see your app
When you’re ready to deploy to production, create a minified bundle with
npm run build
You don’t need to install or configure tools like Webpack or Babel.
They are preconfigured and hidden so that you can focus on the code.
Just clone the repo, and you’re good to go.
You’ll need to have Node 8.16.0 or Node 10.16.0 or later version on your local development machine
(but it’s not required on the server). You can use nvm (macOS/Linux) or nvm-windows to easily switch Node
versions between different projects.
It will create a directory called my-app inside the current folder. Inside that directory, it will generate the initial project structure and install the transitive dependencies:
react-kit
├── README.md
├── node_modules
├── package.json
├── package-lock.json
├── .gitignore
├── index.html
├── server.js
├── webpack.config.js
├── .babelrc
├── src
├── components
└── Home.js
├── containers
└── Container.js
├── layout
└── Header.js
├── routes
└── index.js
├── styles
└── App.css
├── images
├── logo.png
└── Home.jpg
├── App.js
├── index.js
└── index.html
Once the installation is done, you can open your project folder:
cd react-starter-kitRuns the app in development mode.
Open http://localhost:8080 to view it in the browser.
The page will automatically reload if you make changes to the code.
You will see the build errors and lint warnings in the console.
npm run build
Builds the app for production to the build
folder.
It correctly bundles React in production mode and optimizes the build for the best performance.
The build is minified and the filenames include the hashes.
Your app is ready to be deployed.
To deploy your app simply run the command npm run production