Fix template path resolving regexp to support loader query parameters (#542)

This commit is contained in:
Peach 2017-01-11 17:09:30 +08:00 committed by Jan Nicklas
parent 26c95e9c4b
commit 1b4f8efe94
1 changed files with 1 additions and 1 deletions

View File

@ -606,7 +606,7 @@ HtmlWebpackPlugin.prototype.getFullTemplatePath = function (template, context) {
}
// Resolve template path
return template.replace(
/([!])([^/\\][^!?]+|[^/\\!?])($|\?.+$)/,
/([!])([^/\\][^!?]+|[^/\\!?])($|\?[^!?\n]+$)/,
function (match, prefix, filepath, postfix) {
return prefix + path.resolve(filepath) + postfix;
});