-
-
Notifications
You must be signed in to change notification settings - Fork 13
Vite & monaco-editor-workers #67
Comments
Hi @cdietrich monaco-editor-workers was designed to be used without any bundler in pure html/javascript. I want to propose some new approach with TypeFox/monaco-languageclient#600 that let's you override the default. You can get some inspiration here: https://github.com/CodinGame/monaco-vscode-api/blob/main/demo/src/setup.common.ts#L150-L167 I did so, too. 😊 I guess you are interested in |
monaco seeems to whine if there is no worker. |
Yes, it likes the editor to be in a worker. I will work on the bespoke issue above today and move this topic forward along |
@cdietrich new preview release contain the new implementation, they are listed here: TypeFox/monaco-languageclient#600 (comment) It is more versatile, because you have various possibilities to configure or overwrite it. Here are example how to use it. Use pre-bundled version; Provide your own (compatible with vite and webpack): |
vite and webpack need to understand the |
@kaisalmen is there a sample of a dependency list that works together? the like of
e.g. where is npm:@codingame/monaco-editor-treemended gone my wip work is here: simply adding |
@cdietrich Regarding ⬆️ sorry, I have not received a notification or overlooked it. |
|
@kaisalmen hmmmm still have problems to get this running ✘ [ERROR] No matching export in "node_modules/monaco-editor/api.js" for import "editor"
Update: problem solved |
@cdietrich did you define it like this in the package.json?
|
yes now i use it consistently and it works. |
Hi, how to bundle monaco-editor-workers with vite? is there any example that works with import meta url?
The text was updated successfully, but these errors were encountered: