Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/daveiano/react-static-pages
Template project structure for a ReactJS driven static HTML rendered website.
https://github.com/daveiano/react-static-pages
babel babel7 javascript nodejs reactjs webpack webpack4
Last synced: about 1 month ago
JSON representation
Template project structure for a ReactJS driven static HTML rendered website.
- Host: GitHub
- URL: https://github.com/daveiano/react-static-pages
- Owner: Daveiano
- License: mit
- Created: 2019-01-17T20:21:45.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2023-01-14T00:20:27.000Z (about 2 years ago)
- Last Synced: 2024-11-09T14:30:20.129Z (3 months ago)
- Topics: babel, babel7, javascript, nodejs, reactjs, webpack, webpack4
- Language: JavaScript
- Homepage:
- Size: 1.47 MB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 9
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# React Static Pages
Template project structure for a ReactJS driven static HTML rendered website. JSX and SCSS is transpiled via webpack@4. A node script `generate-html` is used to generate a index.html with a redux store embed as json data.## Features
* JSX/ES6 transpiling via babel@7
* SCSS transpiling via node-sass and postcss
* Basic React/Router/Redux Setup
* Bootstrap & ESLint
* Generating HTML with ejs and saving to file via NodeJS## Usage
### Development
#### `npm run dev`
* Cleans up the dist/ folder (where the assets will be saved)
* Copy static assets (e.g. manifest.json) to the dist/ folder
* Transpiles the source files to ES5 for NodeJS and watches for changes to retranspile
* Starting webpack-dev-server
* Start nodemon to regenerate the HTML when changes are made### Build
#### `npm run build`
* Cleans up the dist/ folder (where the assets will be saved)
* Transpiles the source files to ES5 for NodeJS
* Webpack builds the bundle.js and style.css
* Node builds the HTML file from the transpiled source files
* Copy static assets (e.g. manifest.json) to the dist/ folder