@echo-lingua/i18n-core
v0.2.0
Published
Shared, dependency-free primitives for Echo Lingua i18n: the el-* flag vocabulary + conflict detection, CLDR plural tables, the catalog key, and the compiled-catalog types.
Maintainers
Readme
@echo-lingua/i18n-core
The small, dependency-free primitives shared by the two halves of Echo Lingua's i18n toolchain:
@echo-lingua/i18n(the JS/TS runtime) and@echo-lingua/i18n-cli(the project-agnostic extractor and compiler).
Both depend on this package so they agree on the shared vocabulary without one depending on the other.
What's here
ELandEchoLinguaFlag: the appliedel-*flag vocabulary (context, quality, cache, lock, ignore, translate-quotes, translate-attrs), plusdetectFlagConflicts/reconcileFlags.- CLDR plural tables and helpers:
PLURAL_FORMS,PLURAL_CATEGORIES,pluralCategoriesFor,pluralFormsFor,expectedNplurals,npluralsFromHeader,DEFAULT_PLURAL_FORMS. catalogKey(msgctxt, msgid): the one place that decides how a compiled entry is keyed, so the runtime's lookup and the compiler's output never disagree.- Catalog types:
Catalog,CatalogEntry,LocaleCatalog.
These values mirror @echo-lingua/shared-types (the pipeline's source of truth) and are drift-guarded
by a test, so this package stays publishable with zero @echo-lingua/* runtime dependencies.
You usually don't install this directly: it comes in transitively with @echo-lingua/i18n or
@echo-lingua/i18n-cli. Depend on it only if you are building your own tooling against the shared
vocabulary.
