Skip to content

Commit

Permalink
Migrated to new babel-plugin-pkg
Browse files Browse the repository at this point in the history
Signed-off-by: Jaid <[email protected]>
  • Loading branch information
Jaid committed Jun 19, 2021
1 parent 77e86a1 commit 6dbf3e2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ export default class InjectBrowserSyncPlugin {
* @param {import("webpack").Compiler} compiler
*/
apply(compiler) {
compiler.hooks.compilation.tap(_PKG_NAME, compilation => {
HtmlWebpackPlugin.getHooks(compilation).beforeEmit.tapAsync(_PKG_NAME, (data, cb) => {
compiler.hooks.compilation.tap(process.env.REPLACE_PKG_NAME, compilation => {
HtmlWebpackPlugin.getHooks(compilation).beforeEmit.tapAsync(process.env.REPLACE_PKG_NAME, (data, cb) => {
if (this.options.position === "end") {
data.html = insertStringBefore(data.html, "</body>", this.options.content)
} else {
Expand Down

0 comments on commit 6dbf3e2

Please sign in to comment.