Skip to content

Commit 7539425

Browse files
committed
fix: chage the default test scope to avoid targeting map files or gzip files
1 parent a967440 commit 7539425

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,8 +60,8 @@ module.exports = {
6060
plugins: [
6161
new HtmlWebpackPlugin(),
6262
new HtmlInlineScriptPlugin([
63-
/runtime~.+[.]js/,
64-
/app~.+[.]js/
63+
/runtime~.+[.]js$/,
64+
/app~.+[.]js$/
6565
]),
6666
]
6767
}

src/HtmlInlineScriptPlugin.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ class HtmlInlineScriptPlugin implements WebpackPluginInstance {
88
tests: RegExp[];
99

1010
constructor(tests?: RegExp[]) {
11-
this.tests = tests || [/.+[.]js/];
11+
this.tests = tests || [/.+[.]js$/];
1212
}
1313

1414
isFileNeedsToBeInlined(

0 commit comments

Comments
 (0)