mirror of
https://github.com/reduxjs/redux-devtools.git
synced 2024-12-01 14:03:52 +03:00
37 lines
778 B
JavaScript
37 lines
778 B
JavaScript
var path = require('path');
|
|
var webpack = require('webpack');
|
|
|
|
module.exports = {
|
|
mode: process.env.NODE_ENV === 'production' ? 'production' : 'development',
|
|
devtool: 'eval-source-map',
|
|
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()],
|
|
resolve: {
|
|
extensions: ['.js'],
|
|
},
|
|
module: {
|
|
rules: [
|
|
{
|
|
test: /\.js$/,
|
|
loaders: ['babel-loader'],
|
|
exclude: /node_modules/,
|
|
include: __dirname,
|
|
},
|
|
],
|
|
},
|
|
devServer: {
|
|
historyApiFallback: true,
|
|
hot: true,
|
|
port: 3000,
|
|
},
|
|
};
|