1
0
Fork 0
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:
Tim Neutkens 2018-03-31 16:08:16 +02:00 committed by GitHub
parent 43fe9ace54
commit a785f303f4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -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}`)
}