unstale

npm / pofile-ts

pofile-ts

What changed in pofile-ts 2 to 4, from its official release notes, upgrade guides and advisories. Sources checked 2026-10-25.

15 breaking30 new APIs and options8 performance3 behavior and defaults3 fixes and other

See which of these apply to your code, ranked, in your agent:

npx @unstale/cli init

@unstale/cli 0.2.7 on npm

pofile-ts 413 changes

Breaking changes 4

  • The helper was removed because node types are self-documenting.

    4.0.0release notes

  • IcuErrorKind is now just the 'SYNTAX_ERROR' string type.

    4.0.0release notes

  • IcuNodeType is now a string union of literal, argument, number, date, time, select, plural, pound, and tag instead of a numeric enum.

    4.0.0release notes

  • Renames ArgType to ParentArgType.

    4.0.0release notes

New APIs and options 9

  • Adds more than 50 built-in format styles for number, date, time, and list formatting.

    4.0.0release notes

  • Adds a factory for creating pre-configured compilers.

    4.0.0release notes

  • Adds support for custom number, date, time, and list format styles.

    4.0.0release notes

  • Adds extended Intl format types for list, duration, relativeTime, and displayNames.

    4.0.0release notes

  • Adds getPluralFormsHeader.

    4.0.0release notes

  • Adds hasSelectOrdinal.

    4.0.0release notes

  • Adds metadata support for translation items.

    4.0.0release notes

  • Adds typed style properties aligned with Intl APIs.

    4.0.0release notes

  • Supports supplying a dynamic currency through values.currency.

    4.0.0release notes

pofile-ts 338 changes

Breaking changes 6

  • Plural rules are now compliant with CLDR 48, which may affect pluralization results.

    3.6.0release notes

  • The default export is removed; import named exports instead.

    3.0.0release notes

  • The Item class is removed; use the functional API instead.

    3.0.0release notes

  • The PO class is removed; use the functional API instead.

    3.0.0release notes

  • PoFile is exported as an interface instead of a class.

    3.0.0release notes

  • PoItem is exported as an interface instead of a class.

    3.0.0release notes

New APIs and options 21

  • Adds compileCatalog() for compiling catalogs.

    3.7.0release notes

  • Adds compileIcu() for runtime message compilation.

    3.7.0release notes

  • Adds generateCompiledCode() for generating compiled code.

    3.7.0release notes

  • Adds an ICU MessageFormat v1 parser.

    3.7.0release notes

  • Adds getPluralSamples as a new utility, exported from index.

    3.5.0release notes

  • Adds parsePluralFormsHeader as a new utility, exported from index.

    3.5.0release notes

  • Adds splitMultilineComments as a new helper, exported from index.

    3.5.0release notes

  • Adds helpers for converting catalogs.

    3.3.0release notes

  • Adds support for CLDR plural categories.

    3.3.0release notes

  • Adds a helper for creating default headers.

    3.3.0release notes

  • Adds an option for better TMS readability.

    3.3.0release notes

  • Adds a helper for formatting PO dates.

    3.3.0release notes

  • Adds conversion from Gettext to ICU.

    3.3.0release notes

  • Adds utilities for generating message IDs.

    3.3.0release notes

  • Adds utilities for parsing and formatting references.

    3.3.0release notes

  • Adds SerializeOptions for Crowdin-compatible output format.

    3.1.0release notes

  • Create an item with the new functional API.

    3.0.0release notes

  • Create a PO file with the new functional API.

    3.0.0release notes

  • Parse PO content with the new functional API.

    3.0.0release notes

  • Serialize an item with the new functional API.

    3.0.0release notes

  • Serialize a PO file with the new functional API.

    3.0.0release notes

Performance 8

  • Optimizes hot paths in new helper functions.

    3.3.0release notes

  • Optimizes plural serialization.

    3.3.0release notes

  • String extraction uses indexOf and a fast path for unescaping.

    3.2.0release notes

  • Replacing a regular expression with startsWith and inlining the obsolete check improves performance.

    3.2.0release notes

  • Pre-compiled regular expressions and native methods optimize parsing.

    3.2.0release notes

  • First-character dispatch and inline plural-index extraction improve performance.

    3.2.0release notes

  • Fast-path escaping and loop improvements optimize serialization.

    3.2.0release notes

  • A fast path for simple strings and optimized line folding improve performance.

    3.2.0release notes

Behavior and default changes 2

  • Supports numeric tags such as <0> and <1> for Lingui compatibility.

    3.7.0release notes

  • Message IDs use 8-character Base64URL encoding.

    3.3.0release notes

Fixes and other changes 1

  • Robustness for partial or incomplete input is improved.

    3.4.0release notes

pofile-ts 28 changes

Breaking changes 5

  • The load() method was removed for browser compatibility.

    2.2.0release notes

  • The save() method was removed for browser compatibility.

    2.2.0release notes

  • The minimum supported Node.js version is now 22.

    2.0.0release notes

  • PO.load() now returns Promise<PO> instead of using callbacks.

    2.0.0release notes

  • po.save() now returns Promise<void> instead of using callbacks.

    2.0.0release notes

Behavior and default changes 1

  • Adds support for running pofile-ts on Node.js 20.

    2.1.0release notes

Fixes and other changes 2

  • Uses separate type declarations for ESM and CJS exports, improving type resolution for consumers of either module format.

    2.0.3release notes

  • The PO.ts filename case was corrected.

    2.0.0release notes