Repository navigation
Releases: MoeForge/moejs
Releases · MoeForge/moejs
Release list
v0.1.0-alpha.10
- Intl:
Locale,Segmenter,NumberFormat,DateTimeFormat,PluralRulesandsupportedValuesOf, with CLDR 48 data for 11 languages. ThetoLocaleStringmethods format through them. (#4) - The
webapipackage puts fetch, Headers, Request, Response, the Streams, AbortController, URL and performance on a runtime with an event loop. The host'shttp.Clientand an allow hook decide where fetch goes. (#5) MemoryLimitcounts what a program keeps: past the limit, moejs measures the live heap before it stops the program. An event loop's budget covers the whole run, andeventloop.Options.ResetMemoryPerTaskgives each task its own.- A context can stop a compile, and
CompileFunctionandCompileFunctionTScompile a function from its parameters and body. - Faster property lookups cut a new-api plugin hook call by about 9 %.
Every API change is an addition. A stripped binary grows by about 1.3 MB, most of it Intl's data. A program that includes moejs ships sections 1 to 4 of the new THIRD_PARTY_NOTICES. The full list is in #6.
- 新增 Intl:
Locale、Segmenter、NumberFormat、DateTimeFormat、PluralRules和supportedValuesOf,数据来自 CLDR 48,覆盖 11 种语言。各类型的toLocaleString也用它们格式化。(#4) webapi包在带事件循环的运行时上提供 fetch、Headers、Request、Response、Streams、AbortController、URL 和 performance。fetch 能访问哪里,由宿主的http.Client和放行钩子决定。(#5)- 内存上限按程序留住的内存计算:超过上限时,moejs 先测量存活的内存,再决定是否停止程序。事件循环的额度覆盖整次运行,设置
eventloop.Options.ResetMemoryPerTask后每个任务单独计算。 - context 可以停止编译,
CompileFunction和CompileFunctionTS用参数和函数体的源码编译出函数。 - 属性查找更快,new-api 插件钩子调用的耗时因此减少约 9%。
所有 API 变化都是新增。去掉符号的二进制约增加 1.3 MB,主要是 Intl 的数据。嵌入 moejs 的程序需要附带新增的 THIRD_PARTY_NOTICES 第 1 到 4 节。完整改动见 #6。

