-
Notifications
You must be signed in to change notification settings - Fork 182
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Handling of horizontal fallbacks #259
Comments
For DateTime 0.1 needs I'm planning to keep
|
Does not change the need to address it. Just making sure the description / examples are accurate. |
Shared https://docs.google.com/document/d/19iJb3NSmy0frue3zBmHMibTg2PCgkRCRKNnqQhMfy4Y/ |
While working on the data for DateTimeFormat, we started touching on the topic of fallbacks for missing data fields. Examples from the realm of 0.1 are:
cs
locale, we don't have it: https://github.com/unicode-cldr/cldr-dates-modern/blob/master/main/cs/ca-gregorian.json#L14stand_alone
context for weekday names is the same asformat
, do we want to return both like CLDR-JSON does foren
- https://github.com/unicode-cldr/cldr-dates-modern/blob/master/main/en/ca-gregorian.json#L13long
- https://github.com/unicode-cldr/cldr-dates-modern/blob/master/main/so/ca-gregorian.json#L277 ?The two drives that are extremes are:
short
tolong
if its missing? Maybe in some scenario user will want to fallback differently?If we go with
fallback in the provider
, we're likely going to have to add ability to get data without the fallback. If we go with fallback in hands of consumer, we will need to help consumers know how to fallback and there's going to be a number of repetitive pieces of fallbacking in consumers.Finally, expanding all data in provider means more data to carry over the wire. A good example is the second one - for locales where
stand_alone
matchesformat
contexts, we could just carry overformat
and setstand_alone
tonull
and the consumer then can say "if there is stand_alone, use it, if not, fallback on format".But if we expand all fallbacks in Provider, we'll have to for all locales carry duplicated data so that user can infallibly take
stand_alone
.I believe that, as in most cases, we'll be looking for the "third path" somewhere between those two extremes, and we'll need to resolve it on per-case bases, but I think that encoding in wiki (https://github.com/unicode-org/icu4x/wiki/Hooking-up-a-DataProvider) or docs some guidelines on how to generally make decisions on what is going to be expanded in Provider vs. in consumer, is in our best interest, so let's discuss it!
The text was updated successfully, but these errors were encountered: