Skip to content

Instantly share code, notes, and snippets.

@c0debreaker
Created August 15, 2016 06:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save c0debreaker/3f02a80db2a7b54a1a31d27054d61a0b to your computer and use it in GitHub Desktop.
Save c0debreaker/3f02a80db2a7b54a1a31d27054d61a0b to your computer and use it in GitHub Desktop.
var path = require('path');
var merge = require('webpack-merge');
var webpack = require('webpack');
var HtmlWebpackPlugin = require('html-webpack-plugin');
var webpackConfig = require('./webpack.config.js');
webpackConfig = merge(webpackConfig, {
devtool: 'inline-source-map',
entry: {
ife: [
'webpack/hot/dev-server',
'webpack-dev-server/client?http://localhost:8001'
],
test: [
'webpack/hot/dev-server',
'webpack-dev-server/client?http://localhost:8001',
'mocha!' + path.resolve(__dirname, 'entry_points', 'test', 'index.js')
]
},
plugins: [
new webpack.HotModuleReplacementPlugin(),
new HtmlWebpackPlugin({
title: 'Sample Tests',
filename: 'test.html',
inject: 'body',
chunks: ['test']
})
]
});
webpackConfig.resolve.root.unshift(
path.resolve(__dirname, 'submodules', 'overrides')
);
module.exports = webpackConfig;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment