React Redux Webpack Babel Koa setup for kickstarting project in no time
This repo is for those who doesn't want to mess up with react webpack babel setup. This app does it for you. You start writing your application logic starting from "App.js"
Libraries used
- React v15.2
- Redux v3.6
- React-Router v2.8
- Webpack v4.20.2
- Webpack dev server v3.1.9
- Babel v7
- koa v1.2
Instructions
-
clone the repo:
git clone https://github.com/shek8034/react-webpack-setup.git -
Run
npm install -
For development version, follow these steps:-
a)npm run devto start webpack dev server.
b) Hithttp://localhost:8080and you app is served by webpack dev server. It uses hot reloading, so any chagne you make in your code with be built automatically and reflected in the browser. -
For production build, follow these steps:-
a)npm run buildto create a dist directory with production build. It has app.js, app.css and vendor.js code separated.
b)node server.jsto run local node web server and hithttp://localhost:8000
c) For deployment, publish dist directory
Notes
I will keep updating this repo and will try to make it more resuable.
Contributions
Contributions are welcome and if someone wants to add something to the repo and improve it, please go ahead and raise PR or write to me [email protected]
LICENSE
MIT