chore: update all dependencies (#699)
This commit is contained in:
@@ -2,32 +2,33 @@ const { merge } = require('webpack-merge');
|
||||
const config = require('./webpack.config.js');
|
||||
const HtmlWebpackPlugin = require('html-webpack-plugin');
|
||||
|
||||
const WebEnv = {
|
||||
platform: 'web',
|
||||
};
|
||||
|
||||
module.exports = (env, argv) => {
|
||||
const port = argv.port || 3001;
|
||||
return merge(config(env, argv), {
|
||||
return merge(config(Object.assign(env, WebEnv), argv), {
|
||||
mode: 'development',
|
||||
/** Only create an html file for the dev-server */
|
||||
plugins: argv.liveReload ? [
|
||||
optimization: {
|
||||
minimize: false,
|
||||
},
|
||||
plugins: [
|
||||
new HtmlWebpackPlugin({
|
||||
template: './index.html',
|
||||
inject: true,
|
||||
templateParameters: {
|
||||
env: process.env
|
||||
env: process.env,
|
||||
},
|
||||
}),
|
||||
] : [],
|
||||
],
|
||||
devServer: {
|
||||
proxy: {
|
||||
'/extensions': {
|
||||
target: `http://localhost:${port}`,
|
||||
pathRewrite: { '^/extensions': '/public/extensions' }
|
||||
},
|
||||
'/assets': {
|
||||
target: `http://localhost:${port}`,
|
||||
pathRewrite: { '^/assets': '/public/assets' }
|
||||
},
|
||||
},
|
||||
hot: 'only',
|
||||
static: './',
|
||||
port,
|
||||
writeToDisk: argv.writeToDisk,
|
||||
}
|
||||
devMiddleware: {
|
||||
writeToDisk: argv.writeToDisk,
|
||||
},
|
||||
},
|
||||
});
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user