Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
12 changed files
with
20,496 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
node_modules |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,35 @@ | ||
# react-project-starter | ||
Simple React.js project starter kit. | ||
# Simple React.js Project Starter Kit | ||
|
||
## Install | ||
|
||
1. `npm install` | ||
2. `npm install --global http-server` | ||
|
||
## Run | ||
|
||
1. `gulp` | ||
2. `http-server ./build` | ||
3. Open `http://localhost:8080` in a web browser. | ||
|
||
## Project Structure | ||
|
||
+ `source` - all source files. | ||
+ `js` - all JavaScript files. | ||
+ `components` - all React.js component files. | ||
+ `Application.jsx` - React.js component that encapsulates the entire React.js application. | ||
+ `app.jsx` - main React.js application file that renders `Application.jsx` component. | ||
+ `index.html` - main HTML file. | ||
+ `build` - all build files. | ||
+ `js` - all JavaScript files. | ||
+ `app.js` - bundled (and minified) JavaScript file. | ||
+ `index.html` - main HTML file. | ||
|
||
## Helpful Bash Scripts | ||
|
||
`./commit-and-push-to-github.sh` - commits all changes in working directory and pushes them to GitHub. | ||
`./build-for-production.sh` - exports environment variable and runs Gulp task. | ||
`./publish-on-github-pages.sh` - runs `./commit-and-push-to-github.sh`, `./build-for-production.sh` and pushes `./build` directory to `gh-pages` branch on GitHub. | ||
|
||
## Author | ||
|
||
[Artemij Fedosejev](http://artemij.com) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#!/bin/bash | ||
|
||
# React needs this for production build | ||
export NODE_ENV=production | ||
|
||
# Run Gulp task | ||
gulp build-for-production |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<!doctype html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="utf-8" /> | ||
<meta http-equiv="x-ua-compatible" content="ie=edge, chrome=1" /> | ||
<title>Application</title> | ||
<link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css"> | ||
</head> | ||
<body> | ||
<div data-react-application> | ||
<h5 class="text-center text-muted">Loading application...</h5> | ||
</div> | ||
|
||
<script src="./js/app.js"></script> | ||
</body> | ||
</html> |
Oops, something went wrong.