CodinGame / monaco-vscode-api

VSCode public API plugged on the monaco editor
MIT License
208 stars 29 forks source link

VSCode Intl usage is problem for all of us? #397

Closed BusinessDuck closed 1 month ago

BusinessDuck commented 2 months ago

Hi guys!

Let me say thanks for latest update. You are on the right way! All global changes that was maded by tour teams is really impressive!

Lets discuss a problem that was come from VScode last update here

That's because VCode need to work better with chinese locales, emojis and other text stuff... described here

This compatibility list is looks really bad for Segmenter https://caniuse.com/?search=Intl.Segmenter. Its turned off many FF versions except latest.

Here is an example how to a bit more friendly use that new functionality in JS.

This isn't looks like a problem for VSCode, because they working inside Electron and most chromium based environments. But other projects who based on Monaco stack they don't want to get broken clients in FF browser.

Lets discuss that problem here, should we go to VSCode dev or not... what u think so?

CGNonofr commented 2 months ago

I don't think that's a problem of monaco-vscode-api specifically as there is a web version of VSCode that should impacted the exact same way. I'm not really familiar with those issues, but if you confirm you have the same issue on vscode.dev, the "fix" should be done on the VSCode side instead

BusinessDuck commented 2 months ago

I'm sure that this is not an monaco-vscode-api problem, the trouble is that for VSCode this is also not a problem, they define their own table of browsers with which they work. I'm 90% sure they will refuse to make smoother support and polyfills.

BusinessDuck commented 2 months ago

Can we not move to the latest version of VSCode containing this update until we restore support for lost clients on FF browsers?

This is not very good for business including codingame, you have lost some users from these browsers.

Any other ideas?

CGNonofr commented 2 months ago

they define their own table of browsers with which they work.

Then we can assume that we use the same table here :)

I'm 90% sure they will refuse to make smoother support and polyfills.

If a polyfill exists, what prevents you from using it?

This is not very good for business including codingame, you have lost some users from these browsers.

What are the consequences of it?

Feel free to stick with a previous version of the library btw.

BusinessDuck commented 2 months ago

https://unpkg.com/browse/monaco-editor@0.47.0/esm/vs/editor/common/core/wordCharacterClassifier.js pay attention it not exists in monaco editor :)

Regarding your questions:

If a polyfill exists, what prevents you from using it?

polyfill > 500kb https://github.com/formatjs/formatjs/tree/main/packages/intl-segmenter this is the smallest, and this is only Segmenter, in general this is a thing, it either works sadly or is large, there are also 2mb

BusinessDuck commented 2 months ago

What are the consequences of it?

Presumably, with monetization, you reduce the part of the audience that will no longer be able to work with your product.

CGNonofr commented 2 months ago

What are the consequences of it?

Presumably, with monetization, you reduce the part of the audience that will no longer be able to work with your product.

I mean... what is visible to the user? what is the bug exactly?

BusinessDuck commented 2 months ago

I mean... what is visible to the user? what is the bug exactly?

I guess that a big new functionality, we need to test it, Intl its not so easy and may produce surprises...

For today i dont have any caughted problems only technical issues like big and non stable polyfills

BusinessDuck commented 2 months ago

Do you already use polyfills for this?

CGNonofr commented 2 months ago

I think I'm really not competent enough to understand what it's really about

I'm surprised such a big changed was not even mentioned in the VSCode release note?

It also seems that all browsers support if for a long time, except FF which supports it for 3 versions, and I believe they enforce the update so there's probably not so many people on old versions of it, isn't it?

BusinessDuck commented 2 months ago

It also seems that all browsers support if for a long time, except FF which supports it for 3 versions, and I believe they enforce the update so there's probably not so many people on old versions of it, isn't it?

Idk, i was also confused by that change

CGNonofr commented 2 months ago

Do you already use polyfills for this?

No, as I said, I'm not even aware of the issues you mentioned, our target is mainly EMEA and US only though

BusinessDuck commented 2 months ago

This is the first release with Intl https://github.com/microsoft/vscode/releases/tag/1.88.1

This issues is contains PR with changes and not mentioned in VSCode release https://github.com/microsoft/vscode/pull/203605

BusinessDuck commented 2 months ago

@alexdima take a look please 🙏

BusinessDuck commented 2 months ago

I have added some overrides for vs, that new file have dummy method and interface extracted from Intl, that will fix all browser problems. Then we need to decide about next step. Let me sync that case with vscode guys.

BusinessDuck commented 2 months ago

All public interfaces (include exported things) is supported correctly

github-actions[bot] commented 1 month ago

This issue is stale because it has been open for 30 days with no activity.

github-actions[bot] commented 1 month ago

This issue was closed because it has been inactive for 14 days since being marked as stale.