Open
Description
webpack/lib/webworker/ImportScriptsChunkLoadingPlugin.js
Lines 22 to 25 in 00e6102
It appears that webpack unnecessarily makes loading additional chunks in worker entrypoints asynchronous, given that the method used to load additional chunks is in fact synchronous.
I ran into this trying to create a custom worker for monaco. It uses importScripts
to load a file from a given URL, and expects something to be synchronously defined after importScripts
has returned (code). This fails if the URL is a webpack bundle generated using importScripts
, but it works if I change asyncChunkLoading
to false
in the above code.