monaco-editor
monaco-editor copied to clipboard
tune(monaco-editor-webpack-plugin): replace editor.main.js
Usually editor functionality used as:
import * as monaco from 'monaco-editor';
this resolves to ./esm/vs/editor/editor.main.js
in package.json.
editor.main.js
includes all feature and languages. Because of this, webpack-plugin
does not work as expected.
This PR proposes replacing editor.main.js
with editor.api.js
and requested features and languages.
Closes #2874
Thanks for your PR! Can you please open an issue to describe the problem that this PR fixes?
Thanks for your PR! Can you please open an issue to describe the problem that this PR fixes?
Should I open an issue with text from the first comment or should I describe something more fully?
Please also describe what you mean with "does not work as expected". Thank you!
Maybe also need to change this line https://github.com/microsoft/monaco-editor/blob/a385674a34a33947483e0f7266b5a7dbcefe9b9d/webpack-plugin/src/index.ts#L315 to check only editor.main.js
Great idea!
To test this change, we adopted the smoke-test to import monaco-editor
(instead of ./esm/vs/editor/editor.api.js
), but unfortunately this breaks CI now.
Can you look into it?
Thank you!
👍 👀
Any chance we can bring this in? We deploy with our own custom language and it's unfortunate to be forced to bundle 89 languages along with it.
Alternatively, does someone have a reasonable workaround for the time being?
We have the same issue, would be great to fix it.
It would be great to have this merged so please don't forget about this PR.