-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathwebpack.config.js
45 lines (42 loc) · 1.01 KB
/
webpack.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
const path = require('path')
const webpack = require('webpack')
module.exports = {
devtool: 'inline-source-map',
entry: './src/client.js',
output: {
path: path.join(__dirname, 'dist/public'),
filename: 'bundle.js',
publicPath: '/public'
},
resolve: {
extensions: ['', '.js', '.jsx']
},
module: {
loaders: [
{
test: /\.jsx?$/,
loader: 'babel',
exclude: /node_modules/,
query: { plugins: [] }
},
{
test: /\.css$/,
loader: 'style!css'
}
]
}
}
// This will make the redux-simpler-router module resolve to the
// latest src instead of using it from npm. Remove this if running
// outside of the source.
// var src = path.join(__dirname, '../../src')
// var fs = require('fs')
// if (fs.existsSync(src)) {
// // Use the latest src
// module.exports.resolve = { alias: { 'react-router-redux': src } }
// module.exports.module.loaders.push({
// test: /\.js$/,
// loaders: ['babel'],
// include: src
// });
// }