File tree Expand file tree Collapse file tree 2 files changed +20
-0
lines changed Expand file tree Collapse file tree 2 files changed +20
-0
lines changed Original file line number Diff line number Diff line change 18
18
"babel-loader" : " ^5.0.0" ,
19
19
"css-loader" : " ^0.12.0" ,
20
20
"esprima-fb" : " 12001.1.0-dev-harmony-fb" ,
21
+ "express" : " ^4.13.3" ,
21
22
"extract-text-webpack-plugin" : " ^0.7.1" ,
22
23
"file-loader" : " ^0.8.1" ,
23
24
"flux" : " ^2.0.3" ,
28
29
"react" : " ^0.13.1" ,
29
30
"react-hot-loader" : " ^1.2.2" ,
30
31
"react-router" : " 0.13.3" ,
32
+ "serve-static" : " ^1.10.0" ,
31
33
"style-loader" : " ^0.12.0" ,
32
34
"stylus-loader" : " ^1.1.0" ,
33
35
"through" : " ^2.3.6" ,
Original file line number Diff line number Diff line change
1
+ "use strict" ;
2
+
3
+ var express = require ( 'express' ) ;
4
+ var serveStatic = require ( 'serve-static' ) ;
5
+ var path = require ( 'path' ) ;
6
+ var staticFolder = path . join ( __dirname , '..' , 'result' ) ;
7
+
8
+ var app = express ( ) ;
9
+ var PORT = 3000 ;
10
+
11
+ app . use ( serveStatic ( staticFolder , {
12
+ index : 'index.html' ,
13
+ extensions : [ 'html' ]
14
+ } ) ) ;
15
+
16
+ app . listen ( PORT , function ( ) {
17
+ console . log ( 'Test server started on ' + PORT + ' port' ) ;
18
+ } ) ;
You can’t perform that action at this time.
0 commit comments