build public path with correct hash value
This commit is contained in:
parent
07d410d477
commit
419c2e6121
2
index.js
2
index.js
|
|
@ -338,7 +338,7 @@ HtmlWebpackPlugin.prototype.htmlWebpackPluginAssets = function (compilation, chu
|
|||
|
||||
// Use the configured public path or build a relative path
|
||||
var publicPath = typeof compilation.options.output.publicPath !== 'undefined'
|
||||
? compilation.options.output.publicPath
|
||||
? compilation.mainTemplate.getPublicPath({hash: webpackStatsJson.hash})
|
||||
: path.relative(path.dirname(self.options.filename), '.').split(path.sep).join('/');
|
||||
|
||||
if (publicPath.length && publicPath.substr(-1, 1) !== '/') {
|
||||
|
|
|
|||
Loading…
Reference in New Issue