Skip to content

marcello3d/react-hotplate

 
 

Repository files navigation

react-hotplate

react-hotplate is a boilerplate for React + Webpack + Express with hot reloading.

It provides both a development mode (npm run dev) and production mode (npm run build && npm start).

It was originally based on gaearon/react-hot-boilerplate and has been updated using gaearon/react-transform-boilerplate.

Development server

npm install
npm run dev
open http://localhost:3200

Now edit src/App.js.
Your changes will appear without reloading the browser like in this video.

Production server usage

npm run build

This will eslint and build JavaScript bundles in ./dist/.

This webpack config is designed to name the files based on a hash. A filename map is generated in ./dist/webpack-assets.json and can be used to generate the appropriate html links.

Start the production server with:

npm start

Notable Modules

Folder structure

The meat of the hotplate code is in server.js and webpack.config.js. Both files look at the NODE_ENV environment variable to determine if it should run in development or production mode.

The files for the app are in src/.

License

The original code this was based on was released under the MIT license. My changes are released under public domain.

About

Live-editing boilerplate for your next Node+ReactJS project

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 96.4%
  • Handlebars 3.6%