Files
raea/runtime/jsengine/js/intl/package.json
shinyobjectz 917bc94f59 Intl on QuickJS: a composition that formats a number works on Windows and Linux (#169)
QuickJS has no Intl, so toLocaleString or Intl.NumberFormat threw "Intl is not defined" off a Mac. FormatJS's polyfills
(MIT) and the CLDR data they carry (Unicode-3.0) are packed in runtime/jsengine/js/intl.pack (2.2 MB, deflate; js/intl
build.ts, versions pinned), and js/intl/loader.js runs the core the first time anything reads Intl or calls a toLocale*
method, and a locale's data the first time something asks for it, so a script that never formats pays nothing. A small
Collator (letters, then accents, then case) backs localeCompare. quickjs_formats_as_javascriptcore_does: fourteen cases
give JavaScriptCore's answers, and on a Mac it asks JavaScriptCore too. Apple builds are unchanged.
2026-11-19 14:30:17 -08:00

19 lines
592 B
JSON

{
"name": "raea-intl",
"private": true,
"description": "QuickJS's Intl (raea-runtime-jsengine): FormatJS's polyfills and their CLDR data, packed by build.ts into ../intl.pack",
"license": "MIT",
"scripts": {
"build": "bun build.ts"
},
"dependencies": {
"@formatjs/intl-getcanonicallocales": "3.3.0",
"@formatjs/intl-locale": "5.4.2",
"@formatjs/intl-pluralrules": "7.0.2",
"@formatjs/intl-numberformat": "10.0.2",
"@formatjs/intl-datetimeformat": "8.0.2",
"@formatjs/intl-relativetimeformat": "13.0.1",
"@formatjs/intl-listformat": "9.0.1"
}
}