feat: reduce number of steps needed to get going for local development (#454)
* feat: reduce number of steps to get going for local development * fix: set default sync server in SNJS * chore: keep --force in submodules command
This commit is contained in:
@@ -1,12 +1,20 @@
|
||||
const merge = require('webpack-merge');
|
||||
const config = require('./webpack.config.js');
|
||||
const HtmlWebpackPlugin = require('html-webpack-plugin');
|
||||
|
||||
module.exports = (env, argv) => {
|
||||
const port = argv.port || 3001;
|
||||
return merge(config(env, argv), {
|
||||
mode: 'development',
|
||||
plugins: [
|
||||
new HtmlWebpackPlugin({
|
||||
template: './index.html',
|
||||
templateParameters: {
|
||||
env: process.env
|
||||
},
|
||||
}),
|
||||
],
|
||||
devServer: {
|
||||
publicPath: '/dist/',
|
||||
proxy: {
|
||||
'/extensions': {
|
||||
target: `http://localhost:${port}`,
|
||||
@@ -15,7 +23,7 @@ module.exports = (env, argv) => {
|
||||
'/assets': {
|
||||
target: `http://localhost:${port}`,
|
||||
pathRewrite: { '^/assets': '/public/assets' }
|
||||
}
|
||||
},
|
||||
},
|
||||
port,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user