Coder Social home page Coder Social logo

daveiano / react-static-pages Goto Github PK

View Code? Open in Web Editor NEW
1.0 2.0 0.0 1.5 MB

Template project structure for a ReactJS driven static HTML rendered website.

License: MIT License

JavaScript 81.87% SCSS 9.22% EJS 8.91%
reactjs nodejs javascript babel7 babel webpack4 webpack

react-static-pages's Introduction

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

react-static-pages's People

Contributors

daveiano avatar dependabot[bot] avatar

Stargazers

 avatar

Watchers

 avatar  avatar

react-static-pages's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.