diff --git a/webpackDevServerConfig.js b/webpackDevServerConfig.js index 9d43429..594941a 100644 --- a/webpackDevServerConfig.js +++ b/webpackDevServerConfig.js @@ -211,7 +211,7 @@ module.exports = async ({ `, ); - const pluginsPattern = /plugins:\s+\[\s+(.*?),?\s+\]/s; + const pluginsPattern = /plugins:\s*\[\s*(.*?),?\s*\]/s; if (pluginsPattern.test(pageWithScript)) { return pageWithScript.replace(