MCPcopy
hub / github.com/formatjs/formatjs / getLocalesFromFiles

Function getLocalesFromFiles

tools/generate-cldr-locales.ts:47–49  ·  view source on GitHub ↗
(files: string[])

Source from the content-addressed store, hash-verified

45}
46
47function getLocalesFromFiles(files: string[]): string[] {
48 return files.map(file => file.split(/[\\/]/)[0]).filter(isCanonicalLocale)
49}
50
51function getLocalesFromJson(root: string, files: string[], jsonPath: string) {
52 return files.flatMap(file => {

Callers 1

mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected