mirror of
				https://github.com/mickael-kerjean/filestash.git
				synced 2025-10-30 17:46:41 +08:00 
			
		
		
		
	cleanup (structure): update code structure
This commit is contained in:
		| @ -1,4 +1,3 @@ | ||||
| // src/app-client.js
 | ||||
| import React from 'react'; | ||||
| import ReactDOM from 'react-dom'; | ||||
| import Router  from './router'; | ||||
| @ -2,12 +2,10 @@ const webpack = require('webpack'); | ||||
| const path = require('path'); | ||||
| const HtmlWebpackPlugin = require('html-webpack-plugin'); | ||||
|  | ||||
|  | ||||
|  | ||||
| let config = { | ||||
|     entry: [ | ||||
|         'babel-polyfill', | ||||
|         path.join(__dirname, 'src', 'client.js') | ||||
|         path.join(__dirname, 'client', 'index.js') | ||||
|     ], | ||||
|     output: { | ||||
|         path: path.join(__dirname, 'server', 'public'), | ||||
| @ -17,7 +15,7 @@ let config = { | ||||
|     module: { | ||||
|         loaders: [ | ||||
|             { | ||||
|                 test: path.join(__dirname, 'src'), | ||||
|                 test: path.join(__dirname, 'client'), | ||||
|                 loader: ['babel-loader'] | ||||
|             }, | ||||
|             { | ||||
| @ -32,7 +30,7 @@ let config = { | ||||
|         }), | ||||
|         new webpack.optimize.OccurrenceOrderPlugin(), | ||||
|         new HtmlWebpackPlugin({ | ||||
|             template: __dirname + '/src/index.html', | ||||
|             template: path.join(__dirname, 'client', 'index.html'), | ||||
|             inject:true | ||||
|         }) | ||||
|     ] | ||||
| @ -57,7 +55,7 @@ if(process.env.NODE_ENV === 'production'){ | ||||
|             } | ||||
|         } | ||||
|     }; | ||||
|     config.entry.push('webpack/hot/only-dev-server'); | ||||
|     //config.entry.push('webpack/hot/only-dev-server'); | ||||
| } | ||||
|  | ||||
|  | ||||
|  | ||||
		Reference in New Issue
	
	Block a user
	 Mickael KERJEAN
					Mickael KERJEAN