redux-devtools/examples/counter/webpack.config.js

44 lines
1.0 KiB
JavaScript
Raw Normal View History

2015-07-14 22:46:44 +03:00
var path = require('path');
var webpack = require('webpack');
module.exports = {
devtool: 'eval',
entry: [
'webpack-dev-server/client?http://localhost:3000',
'webpack/hot/only-dev-server',
'./index'
],
output: {
path: path.join(__dirname, 'dist'),
filename: 'bundle.js',
publicPath: '/static/'
},
plugins: [
new webpack.HotModuleReplacementPlugin(),
new webpack.NoErrorsPlugin()
],
resolve: {
alias: {
2015-07-15 00:11:55 +03:00
'redux-devtools/lib': path.join(__dirname, '..', '..', 'src'),
'redux-devtools': path.join(__dirname, '..', '..', 'src'),
'react': path.join(__dirname, 'node_modules', 'react')
2015-07-14 22:46:44 +03:00
},
extensions: ['', '.js']
},
2015-08-13 01:05:32 +03:00
resolveLoader: {
'fallback': path.join(__dirname, 'node_modules')
},
2015-07-14 22:46:44 +03:00
module: {
loaders: [{
test: /\.js$/,
loaders: ['react-hot', 'babel'],
exclude: /node_modules/,
include: __dirname
}, {
test: /\.js$/,
2015-08-13 01:05:32 +03:00
loaders: ['react-hot', 'babel'],
2015-07-14 22:46:44 +03:00
include: path.join(__dirname, '..', '..', 'src')
}]
}
};