2016-12-05 22:11:55 +02:00
|
|
|
// const graphql = require('../../cloudapi-graphql/src/endpoint');
|
|
|
|
const plugins = require('./plugins');
|
|
|
|
const base = require('./base');
|
2016-10-20 04:14:26 +03:00
|
|
|
|
|
|
|
const devServer = {
|
|
|
|
hot: true,
|
|
|
|
compress: true,
|
|
|
|
lazy: false,
|
2016-12-05 22:11:55 +02:00
|
|
|
publicPath: base.output.publicPath,
|
2016-10-20 04:14:26 +03:00
|
|
|
setup: (app) => {
|
2016-12-05 22:11:55 +02:00
|
|
|
// app.use('/graphql', graphql);
|
2016-10-20 04:14:26 +03:00
|
|
|
},
|
|
|
|
historyApiFallback: {
|
|
|
|
index: './static/index.html'
|
|
|
|
}
|
|
|
|
};
|
|
|
|
|
2016-12-05 22:11:55 +02:00
|
|
|
module.exports = Object.assign(base, {
|
|
|
|
devtool: 'eval-source-map',
|
2016-10-20 04:14:26 +03:00
|
|
|
entry: [
|
|
|
|
'react-hot-loader/patch',
|
|
|
|
'webpack-dev-server/client?http://localhost:8080',
|
|
|
|
'webpack/hot/only-dev-server',
|
2016-12-12 18:27:33 +02:00
|
|
|
base.entry
|
2016-10-20 04:14:26 +03:00
|
|
|
],
|
2016-12-05 22:11:55 +02:00
|
|
|
plugins: base.plugins.concat([
|
|
|
|
plugins['named-modules'],
|
|
|
|
plugins['hot-module-replacement']
|
2016-10-20 04:14:26 +03:00
|
|
|
]),
|
|
|
|
devServer
|
|
|
|
});
|