Skip to content

Commit a908b14

Browse files
author
Jack Hsu
committed
fixes webpack config and makes running server much easier
1 parent aae2e29 commit a908b14

28 files changed

+300
-426
lines changed

.babelrc

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,7 @@
11
{
22
"presets": [
3-
[
4-
"es2015",
5-
{
6-
"modules": false
7-
}
8-
],
3+
[ "latest", { "modules": false} ],
94
"stage-2",
10-
"react"],
11-
"plugins": ["react-hot-loader/babel"]
5+
"react"
6+
]
127
}
File renamed without changes.

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
.vscode/
22
.idea/
3+
build/
34
node_modules/
45
typings/
56
npm-debug.log
6-
build/stats-dev.json*
77
tmp/
88
dist/
99
.sw[a-z]

README.md

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -14,37 +14,38 @@ Read more about it in my blog post: http://jaysoo.ca/2015/09/26/typed-react-and-
1414

1515
Requirement:
1616

17-
- NodeJS 4+
17+
- NodeJS 6+
1818

1919
Install dependencies:
2020

2121
```
2222
npm install
2323
```
24-
## Running production server
24+
25+
## Running development server
26+
27+
Run webpack dev server (for assets):
2528

2629
```
2730
npm start
2831
```
2932

30-
Visit [http://localhost:8000/](http://localhost:8000/).
33+
Visit [http://localhost:3000/](http://localhost:3000/).
3134

32-
**Note:** This will run the pre-built JavaScript files, if you want to play around with the source
33-
you need to run the development server with webpack dev server (See below).
35+
## Running production server
3436

35-
---
37+
```
38+
npm run start:prod
39+
```
3640

37-
## Running development server
41+
Visit [http://localhost:3000/](http://localhost:3000/).
3842

39-
Run webpack dev server (for assets):
43+
This will build the assets for you on the first run. For subsequent starts, you should run:
4044

4145
```
42-
npm run start:dev
46+
npm run build
4347
```
4448

45-
Visit [http://localhost:8000/](http://localhost:8000/).
46-
47-
4849
### Testing
4950

5051
To run tests, use:

build/public/debugging/main.css.map

Lines changed: 0 additions & 1 deletion
This file was deleted.

build/public/debugging/main.js.map

Lines changed: 0 additions & 1 deletion
This file was deleted.

build/public/debugging/todos.css.map

Lines changed: 0 additions & 1 deletion
This file was deleted.

build/public/debugging/todos.js.map

Lines changed: 0 additions & 1 deletion
This file was deleted.

build/public/main.css

Lines changed: 0 additions & 2 deletions
This file was deleted.

build/public/main.js

Lines changed: 0 additions & 25 deletions
This file was deleted.

0 commit comments

Comments
 (0)