Open Aayush04 opened 2 years ago
I think you're just lucky that there is no recent syntaxes in the monaco editor api only, it may change in the future
Monaco editor doesn't transpile the code into old es5 anymore, so you have to do it yourself, and that's a good thing: you can decide your level of browser compatibility
Btw I still think it could be a good idea to not force the user to import everything from monaco
Hello, I am facing issue in building react application having this dependency. I am getting error in with the unnecessary monaco files which II guess not required for collab extension.
If I rebuild the monaco-collab-ext with replacing
import * as monaco from "monaco-editor"
withimport * as monaco from "monaco-editor/esm/vs/editor/editor.api"
Then the above issue is not coming and everything works fine. So, my suggestion is why not to just import monaco api's instead of whole heavy monaco editor installation. If other things not required. Also, on searching everywhere the above error could also be solved by changing webpack configuration. But my doubt is why to go into hassle of changing/overriding webpack config, if it could easliy solve by importing monaco api only.What is the opinion about this issue?