BlazorMonaco
BlazorMonaco copied to clipboard
Uncaught Error: Can only have one anonymous define call per script file with Blazor Server
Finally I can use Monaco Editor using your library in my project. but I am having this issue .
I would like to know how to solve this issue.
Uncaught Error: Can only have one anonymous define call per script file at r.enqueueDefineAnonymousModule (loader.js:7:5413) at _ (loader.js:8:1734) at Chart.min.js:7:179 at Chart.min.js:7:302 blazor.server.js:1 [2022-02-18T13:50:56.874Z] Information: Normalizing '_blazor' to 'https://localhost:5001/_blazor'. loader.js:1344 Duplicate definition of module 'vs/editor/editor.main.nls'
I found this link but honestly I don't know how to fix it with Blazor Server https://github.com/microsoft/monaco-editor/issues/2283
thank you
You need to load all your java script before you load lib/monaco-editor/min/vs/loader.js