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
This code is not used for workers (but works for the other modules)
Expected Behavior
worker-xml should be loaded from a specified webpack-module
Current Behavior
worker-xml.js is still loaded
Reproduction Steps
Load modules like this in Webpack5 project:
import { Ace, edit, config } from 'ace-builds';
import 'ace-builds/esm-resolver';
You will notice that all modules are properly loaded but workers will fail with 404
Possible Solution
As a workaround you can still use:
import xmlWorkerUrl from 'file-loader!ace-builds/src-noconflict/worker-xml';
config.setModuleUrl('ace/mode/xml_worker', xmlWorkerUrl);
Additional Information/Context
The issue is somewhere inside $createWorkerFromOldConfig. It uses config.moduleUrl(mod, "worker") to get workerUrl. But actually it should refer to dynamicModules somehow
Ace Version / Browser / OS / Keyboard layout
1.32.3
The text was updated successfully, but these errors were encountered:
I think I understand what is the problem here.
You can't use worker loaders because you specifically need worker-url to construct blob-worker. String is needed here.
Maybe you can simply use worker loader directly? Without using a blob?
I see that UIWorkerClient kind of does it but it looks like this function is not used at all. Only WorkerClient is used
Describe the bug
esm-resolver.js
file has the following line to load worker-xml:This code is not used for workers (but works for the other modules)
Expected Behavior
worker-xml should be loaded from a specified webpack-module
Current Behavior
worker-xml.js is still loaded
Reproduction Steps
Load modules like this in Webpack5 project:
You will notice that all modules are properly loaded but workers will fail with 404
Possible Solution
As a workaround you can still use:
Additional Information/Context
The issue is somewhere inside
$createWorkerFromOldConfig
. It usesconfig.moduleUrl(mod, "worker")
to getworkerUrl
. But actually it should refer todynamicModules
somehowAce Version / Browser / OS / Keyboard layout
1.32.3
The text was updated successfully, but these errors were encountered: