On #3, a couple of methods have been defined to help to iterate through the locales. I am considering to improve (and also change) the previous API according to the below:
var cldrData = require("cldr-data");
// List all locales: (no change compared to previous API)
cldrData.availableLocales.forEach(function(locale) {
console.log(locale);
});
// Get the entire supplemental (new method)
cldrData.entireSupplemental();
// Get the entire main for certain locales (new method)
cldrData.entireMain("en", "en-GB", "pt-BR", ...)
// Get certain main file for all locales: (the previous .main() method has been deprecated)
var path = require("path");
cldrData.availableLocales.map(function(locale) {
return cldrData(path.join("main", locale, "numbers"));
});
// Get the entire thing
cldrData.all();
On #3, a couple of methods have been defined to help to iterate through the locales. I am considering to improve (and also change) the previous API according to the below: