Skip to content

"DeprecationWarning: Tapable.plugin is deprecated. Use new API on .hooks instead" in Webpack 4 #154

Open

Description

@JasonKleban

This code is invoking a "DeprecationWarning: Tapable.plugin is deprecated. Use new API on .hooks instead"

const genPluginMethod = (orig, pluginName, smp, type) =>
function(method, func) {
const timeEventName = pluginName + "/" + type + "/" + method;
const wrappedFunc = genWrappedFunc({
func,
smp,
context: this,
timeEventName,
pluginName,
endType: "wrapDone",
});
return orig.plugin(method, wrappedFunc);
};

Perhaps this similar fix in another library could be a guide for a PR here, but the higher-order nature of the code in speed-measure-webpack-plugin make it not obvious to apply.

jantimon/html-webpack-plugin#879 (comment)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions