Skip to content
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

How to get CLDR data? Needs more detailed information. #60

Open
DianaLaa opened this issue Sep 21, 2017 · 6 comments
Open

How to get CLDR data? Needs more detailed information. #60

DianaLaa opened this issue Sep 21, 2017 · 6 comments

Comments

@DianaLaa
Copy link

In my quest to resolve

E_MISSING_CLDR: Missing required CLDR content 'supplemental/likelySubtags'.

I've stumbled across various questions that ask the same thing. None of the answers seems exhaustive. Sorry to open yet another topic, but I think it's needed to have a basic tutorial.

I want two switch between formatting numbers in "en-US" and "nl-NL". So I need both languages configured.

I have found https://github.com/unicode-cldr/cldr-json.

  1. What do I download? Is cldr-core and cldr-numbers enough?
  2. Which version do I get? cldrjs NuGet package is version 0.4.8, but clrd-json has latest version 31.0.1. Does that work together?
  3. Where do I put it, in my project folder structure?
  4. Exactly what JavaScript do I write to bootstrap this in each language?
@samambetov
Copy link

Did you decide it?

@hakrac
Copy link

hakrac commented Aug 17, 2018

Got the same issue but I found this

@yrammos
Copy link

yrammos commented Nov 18, 2019

Yes, the documentation is ambiguous and incomplete to say the least.

@rxaviers
Copy link
Owner

Cldr.js itself requires supplemental/likelySubtags, everything else is optional. It actually depends on the library that uses cldr.js to implement i18n. For example, globalize.js (that uses cldr.js under the hoods) depends on the following for each of its functionalities https://github.com/globalizejs/globalize/#2-cldr-content

I am happy to accept PRs that clarifies the documentation here. Thank you

@yrammos
Copy link

yrammos commented Nov 19, 2019

Thanks, @rxaviers. I realize now that my earlier comment read unnecessarily curt — my apologies.

@markzolotoy
Copy link

I am keeping getting this:
globalize.min.js:1 Uncaught Error: E_MISSING_CLDR: Missing required CLDR content supplemental/likelySubtags.
at u (globalize.min.js:1)
at f (globalize.min.js:1)
at e.n (globalize.min.js:1)
at e.t.emitEvent (event.min.js:1)
at e.trigger (event.min.js:1)
at S.e.get (event.min.js:1)
at p (globalize.min.js:1)
at Function.g.locale (globalize.min.js:1)
at utilities.js:847

Here is what I load:

<script src="https://cdn.jsdelivr.net/npm/[email protected]/supplemental/likelySubtags.json" type="text/javascript"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/cldrjs/0.5.1/cldr.min.js" type="text/javascript"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/cldrjs/0.5.1/cldr/event.min.js" type="text/javascript"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/cldrjs/0.5.1/cldr/supplemental.min.js" type="text/javascript"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/globalize/1.5.0/globalize.min.js" type="text/javascript"></script>

Any idea what's going on?

Thanks

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

No branches or pull requests

6 participants