1
0
mirror of https://github.com/yldio/copilot.git synced 2024-11-28 14:10:04 +02:00
copilot/frontend/webpack/development.js
Sérgio Ramos 0189d7d29a re-organize webpack configuration
- detach plugins configuration
 - use aliases
 - add project root to frontend module resolver
2016-12-05 20:11:55 +00:00

32 lines
714 B
JavaScript

// const graphql = require('../../cloudapi-graphql/src/endpoint');
const plugins = require('./plugins');
const base = require('./base');
const devServer = {
hot: true,
compress: true,
lazy: false,
publicPath: base.output.publicPath,
setup: (app) => {
// app.use('/graphql', graphql);
},
historyApiFallback: {
index: './static/index.html'
}
};
module.exports = Object.assign(base, {
devtool: 'eval-source-map',
entry: [
'react-hot-loader/patch',
'webpack-dev-server/client?http://localhost:8080',
'webpack/hot/only-dev-server',
'./index.js'
],
plugins: base.plugins.concat([
plugins['named-modules'],
plugins['hot-module-replacement']
]),
devServer
});