Skip to content
Teacher Client for the BreatheCode Platform
JavaScript CSS HTML
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github
dist
public
src
.env.dev
.env.prod
.eslintrc
.gitignore
.gitpod.yml
.htaccess
4geeks.ico
README.md
deploy-to-github.js
now.json
package-lock.json
package.json
template.html
webpack.common.js
webpack.dev.js
webpack.prod.js

README.md

WebApp boilerplate with React and Cloud 9

Requirements: Make sure you are using node version 8

  • $ node -v to check which node version you are using
  • $ nvm use 8 to switch to using version 8
  • $ nvm install 8 to install version 8 if necessary
Clone this boilerplate
$ git clone https://github.com/4GeeksAcademy/react-hello-webapp
and install the npm package:
$ npm install

Start coding!

Start the webpack server with live reload:

  • $ npm run c9 for Cloud 9 Users.
  • $ npm run dev-server for windows, mac or linux.

Styles

You can update the styles/index.scss or js/index.js depending on your needs.

Components

Add more files into your ./src/js/components or styles folder as you need them.

Views (Components)

Add more files into your ./src/js/views and import them in ./src/js/layout.jsx.

Context

This boilerplate comes with a centralized general Context API. The file ./src/js/store/store.js has a base structure for the store, we encourage you to change it and adapt it to your needs.

React Context docs

The Context.Provider is already set, you can use the Context.Consumer to get the store and actions from the Context. Check /views/demo.jsx to see a demo.

Publish your website!

This boilerplate is 100% compatible with the free github pages hosting. To publish your website you need to push your code to your github repository and run the following command after:

$ npm run deploy

Note: You will need to configure github pages for the branch gh-pages

You can’t perform that action at this time.