Skip to content
This repository has been archived by the owner on Jan 25, 2022. It is now read-only.

Applying settings from the OS #4

Closed
littledan opened this issue Sep 8, 2018 · 1 comment
Closed

Applying settings from the OS #4

littledan opened this issue Sep 8, 2018 · 1 comment

Comments

@littledan
Copy link
Member

Some earlier discussion about dateStyle/timeStyle in tc39/ecma402#108 included propagating OS settings through. I'm not sure if the current specification is getting at this by the vagueness of BestFormatForStyle, but at least I don't see a way that developers could turn this on or off.

I'd suggest that we make navigator.locales contain the dateStyle/timeStyle (in otherwise unobservable internal slots), allowing the OS options to be selected through that, whereas the CLDR entry would be chosen by another locale. Just implicitly always using the OS options could be bad for multiuser systems and reproducibility (e.g., Node.js), and using navigator.locale centralizes all the fingerprinting surface/new settings.

Another option is to have a particular option in the bag to select whether OS options are used. @rxaviers and I discussed this offline, and we couldn't figure out if there's any time when you really want some of the details in navigator.locales but not all of them. So I'd suggest that we just unconditionally apply the special version if you use navigator.locales and the browser supports it.

@littledan
Copy link
Member Author

We discussed this possibility at the September 2018 Intl call, and decided to leave integration with OS options for a later proposal, and try to get out an MVP that exposed just the CLDR data. It's not clear how/whether browsers should expose this information.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant