-
Notifications
You must be signed in to change notification settings - Fork 394
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
New major version #35
Comments
@samccone do you think this would help accomplish what we are wanting? |
I'd be interested in hearing the architectural goals you're trying to achieve here. The list above is mostly actions and is missing rationale. Hopefully contorting the interface to appease esbench is not the primary driver. |
+1 to @robpalme's question. My only motivation with changes to tappable is as follows
|
This will be removed. Eventually the Tapable base class will be removed, but it will stay for now because of legacy methods.
There will be a |
|
@samccone @robpalme https://medium.com/webpack/the-new-plugin-system-week-22-23-c24e3b22e95 |
+1 to the blog post, it hits every API pain point that I ran into and provides a solid approach for the future. I am excited for the new version! One question that I do have though is what will be the story for people to upgrade? If a plugin is old.. what will be the behavior? Will there be a compat layer to make them work with the new version or will developers have to do the upgrade to see these new API wins? Thanks |
There will be a compat layer. Old plugins should continue to work. Old tapable instances are breaking and need to be changed. Some features are not available in the compat layer, like naming for plugins. |
@sokra I think this change will open open a larger contribution opportunity once we make this major change for webpack v4+. Do you think you could outline a few example plugins and how you might convert old to new api so that I can write a few instructional guide examples for contributors to jump in and help with the refactor? |
What about a new major version with more performance and more features?
arguments
, compile fixed arguments function.new Function(`function x(${args}) ...`)
compiler.plugin("before-run", ...)
compiler.hooks.beforeRun(...)
to allow have typings for these hooks.compiler.hooks.beforeRun("HotModuleReplacementPlugin", () => ...)
hooks.beforeRun({ name: ..., before: "HotModuleReplacementPlugin" }, () => ...)
hooks.beforeRun.intercept(...)
plugin(...)
method can be provided for backward compatibility for plugins.applyPluginsXXX
methods can also be offered for backward compatibility, but trigger a deprecation.plugin
orapplyPluginsXXX
automatically register a compat hook which handle them.The text was updated successfully, but these errors were encountered: