Skip to content

Instantly share code, notes, and snippets.

@bitttttten
Created October 20, 2016 21:32
Show Gist options
  • Select an option

  • Save bitttttten/ba14f95b7d83b17381bfa97ff6affa6b to your computer and use it in GitHub Desktop.

Select an option

Save bitttttten/ba14f95b7d83b17381bfa97ff6affa6b to your computer and use it in GitHub Desktop.
const webpack = require('webpack');
const CaseSensitivePathsPlugin = require('case-sensitive-paths-webpack-plugin')
const HtmlWebpackPlugin = require('html-webpack-plugin')
const loaders = require('./loaders.js')
module.exports = {
entry: [
require.resolve('webpack-dev-server/client') + '?/',
require.resolve('webpack/hot/dev-server'),
'./app/client.js'
],
output: {
path: './build/',
pathinfo: true,
filename: 'hello.js',
publicPath: '/',
},
devtool: 'eval',
devServer: {
historyApiFallback: true,
hot: true
},
module: {
loaders
},
plugins: [
new HtmlWebpackPlugin({
inject: true,
template: './template/index.html',
}),
new webpack.HotModuleReplacementPlugin(),
new CaseSensitivePathsPlugin(),
new webpack.NoErrorsPlugin(),
],
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment