From 41a4af4dbe6742a393c776f02eaf4132b75de41d Mon Sep 17 00:00:00 2001 From: Sam Richard Date: Mon, 12 Aug 2024 17:01:19 -0400 Subject: [PATCH] Configure dev server for HMR --- webpack.dev.js | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/webpack.dev.js b/webpack.dev.js index d01845d..53c3c3e 100644 --- a/webpack.dev.js +++ b/webpack.dev.js @@ -14,13 +14,24 @@ * limitations under the License. */ -const { merge } = require('webpack-merge'); +const {merge} = require('webpack-merge'); const common = require('./webpack.common.js'); module.exports = merge(common, { mode: 'development', devtool: 'inline-source-map', output: { - publicPath: '' + publicPath: '', + }, + devServer: { + port: 4321, + allowedHosts: 'all', + client: { + webSocketURL: { + protocol: 'ws', + hostname: 'localhost', + port: 4321, + }, + }, }, });