-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathwebpack.config.js
38 lines (37 loc) · 1.07 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
var webpack = require('webpack');
module.exports = {
entry: {
app: ['webpack/hot/dev-server', './ui/app.jsx'],
},
output: {
path: './public/build',
filename: 'bundle.js',
publicPath: 'http://localhost:8080/build/'
},
devServer: {
contentBase: './public',
publicPath: 'http://localhost:8080/build/'
},
module: {
loaders: [
{ test: /\.jsx?$/, loaders: ['react-hot', 'babel-loader'], exclude: /node_modules/ },
{ test: /\.json$/, loader: 'json-loader' },
{ test: /\.css$/, loader: 'style-loader!css-loader' },
{ test: /\.scss$/, loader: 'style-loader!css-loader!sass-loader'},
{ test: /\.(png|woff|woff2|eot|ttf|svg)$/, loader: 'url-loader?limit=100000' },
{ test: /\.(jpe|jpg|woff|woff2|eot|ttf|svg)(\?.*$|$)/, loaders: ['file-loader'] }
]
},
node: {
__dirname: true
},
plugins: [
new webpack.HotModuleReplacementPlugin(),
new webpack.DefinePlugin({'global.GENTLY': false})
],
resolve: {
extensions: ['', '.js', '.jsx', '.css'],
modulesDirectories: ['node_modules', __dirname + '/node_modules/font-awesome/css']
},
target: 'electron'
}