mirror of
https://github.com/terribleplan/next.js.git
synced 2024-01-19 02:48:18 +00:00
Match externals ending in .js not everything with .js (#4091)
Makes sure highlight.js/styles/dark.css doesn’t get caught by externals.
This commit is contained in:
parent
43fe9ace54
commit
a785f303f4
|
@ -79,7 +79,7 @@ function externalsConfig (dir, isServer) {
|
|||
return callback()
|
||||
}
|
||||
|
||||
if (res.match(/node_modules[/\\].*\.js/)) {
|
||||
if (res.match(/node_modules[/\\].*\.js$/)) {
|
||||
return callback(null, `commonjs ${request}`)
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue