No Description

Konstantin Tarkus fa11e77ab7 Update npm modules 9 years ago
components 4ed3d62aa9 Remove unused styles from Navigation.scss 9 years ago
lib e2488d5374 Refactor the directory layout 9 years ago
pages 58de8519be Correct typo on internal error page 9 years ago
static e1f47d372e Add a CNAME file 9 years ago
test dccf941824 Update npm packages; use AirBnb settings for ESLint 9 years ago
tools 7bf552fde4 Replace React Hot Loader (depricated) with React Transform 9 years ago
.babelrc bdfc82a852 Initial commit 10 years ago
.editorconfig bdfc82a852 Initial commit 10 years ago
.eslintrc dccf941824 Update npm packages; use AirBnb settings for ESLint 9 years ago
.gitattributes bdfc82a852 Initial commit 10 years ago
.gitignore bdfc82a852 Initial commit 10 years ago
.travis.yml b0650b396f Update README.md 9 years ago
LICENSE.txt a2a2c8f1da Major refactoring 9 years ago
README.md 7bf552fde4 Replace React Hot Loader (depricated) with React Transform 9 years ago
app.js b526067910 Run React app only when DOM content is loaded 9 years ago
config.js a4aac1e4d7 Refactor the directory layout 9 years ago
package.json fa11e77ab7 Update npm modules 9 years ago

README.md

React Static Boilerplate

NPM version NPM downloads Build Status Dependency Status

A static website starter kit powered by React.js and Webpack.

Visit demo site  |  See roadmap  |  Join #react-static-boilerplate chatroom on Gitter to stay up to date.

Features

    ✓ Generates static .html pages from React components
    ✓ Generates routes based on the list of files in the /pages folder
    ✓ Next generation JavaScript with Babel
    ✓ Sass syntax for CSS via postCSS and precss
    ✓ Development web server with BrowserSync and React Transform
    ✓ Bundling and optimization with Webpack
    ✓ Code-splitting and async chunk loading
    ✓ Easy deployment to GitHub Pages, Amazon S3 or Firebase
    ✓ Yeoman generator (generator-react-static)

Directory Layout

.
├── /build/                     # The folder for compiled output
├── /node_modules/              # 3rd-party libraries and utilities
├── /components/                # React components
├── /lib/                       # Libraries and utilities
├── /pages/                     # React.js-based web pages
│   ├── /blog/                  # Blog post entries example
│   ├── /404.js                 # Not Found page
│   ├── /500.js                 # Error page
│   ├── /about.js               # About Us page
│   └── /index.js               # Home page
├── /static/                    # Static files such as favicon.ico etc.
├── /test/                      # Unit and integration tests
├── /tools/                     # Build automation scripts and utilities
│── app.js                      # The main JavaScript file (entry point)
│── config.js                   # Website configuration / settings
│── LICENSE.txt                 # License file
│── package.json                # Dev dependencies and NPM scripts
└── README.md                   # Project overview

Getting Started

Just clone the repo, install Node.js modules and run npm start:

$ git clone -o react-static-boilerplate -b master --single-branch \
      https://github.com/koistya/react-static-boilerplate.git MyApp
$ cd MyApp
$ npm install
$ npm start

Then open http://localhost:3000/ in your browser.

How to Test

The unit tests are powered by chai and mocha.

$ npm test

How to Deploy

$ npm run deploy                # Deploys the project to GitHub Pages

How to Update

You can always fetch and merge the recent changes from this repo back into your own project:

$ git checkout master
$ git fetch react-static-boilerplate
$ git merge react-static-boilerplate/master
$ npm install

Related Projects

Learn More


Made with ♥ by Konstantin Tarkus (@koistya) and contributors  |  MIT License