You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
createChildCompiler API takes three arguments; its name, outputOptions, and plugins. The current implementation in WorkerPlugin doesn't pass the 3rd argument, so the child compiler doesn't has plugins inherited from the parent.
Solution:
Add the 3rd argument and pass compilerOptions.plugin.
I've released this as 2.0.1 - give it a try and let me know if it works. I think we'll probably be playing whack-a-mole disabling plugins for a while though. If it causes too many issues we'll have to switch to having an option of "plugins to allow".
My story is here: https://medium.com/lacolaco-blog/an-issue-around-angular-cli-comlink-workerplugin-585be1c8d087
My friend @manfredsteyer figured out the cause of the error. WorkerPlugin creates a child webpack compiler for worker module's compilation.
https://github.com/GoogleChromeLabs/worker-plugin/blob/master/src/loader.js#L42
createChildCompiler
API takes three arguments; its name, outputOptions, and plugins. The current implementation in WorkerPlugin doesn't pass the 3rd argument, so the child compiler doesn't has plugins inherited from the parent.Solution:
Add the 3rd argument and pass
compilerOptions.plugin
.In my case, it works well as I expected.
If this is by design, I'd like to know the reason.
The text was updated successfully, but these errors were encountered: