From b75462653d11803a428b1d29479e259c3010163f Mon Sep 17 00:00:00 2001 From: Jan Nicklas Date: Tue, 19 Jan 2021 21:22:56 +0100 Subject: [PATCH] feat: provide public path to the alterAssetTags hook --- README.md | 1 + index.js | 1 + lib/hooks.js | 1 + typings.d.ts | 1 + 4 files changed, 4 insertions(+) diff --git a/README.md b/README.md index 9342a5f4..674226d1 100644 --- a/README.md +++ b/README.md @@ -519,6 +519,7 @@ about which values are passed. styles: Array, meta: Array, }, + publicPath: string, outputName: string, plugin: HtmlWebpackPlugin }> diff --git a/index.js b/index.js index a9cfd392..846160c4 100644 --- a/index.js +++ b/index.js @@ -298,6 +298,7 @@ function hookIntoCompiler (compiler, options, plugin) { ] }, outputName: childCompilationOutputName, + publicPath: htmlPublicPath, plugin: plugin })) .then(({ assetTags }) => { diff --git a/lib/hooks.js b/lib/hooks.js index cf6ce139..5013c7a2 100644 --- a/lib/hooks.js +++ b/lib/hooks.js @@ -32,6 +32,7 @@ const AsyncSeriesWaterfallHook = require('tapable').AsyncSeriesWaterfallHook; styles: Array, meta: Array, }, + publicPath: string, outputName: string, plugin: HtmlWebpackPlugin }>, diff --git a/typings.d.ts b/typings.d.ts index ff982069..3bfde0e0 100644 --- a/typings.d.ts +++ b/typings.d.ts @@ -209,6 +209,7 @@ declare namespace HtmlWebpackPlugin { styles: HtmlTagObject[]; meta: HtmlTagObject[]; }; + publicPath: string, outputName: string; plugin: HtmlWebpackPlugin; }>;