emnapi is a Node-API implementation intended for running native Node-API addons on WebAssembly targets. It helps port Node-API native addons to Emscripten, wasi-sdk, clang wasm32 (including pthread/thread support), while aiming to match native Node.js runtime behavior closely. It also powers the WebAssembly feature for napi-rs and provides documentation and guides for building and using it.
Project status
- The repo appears actively maintained, with the most recent GitHub push on 2026-05-28 and multiple versioned updates in 2026 (v1.9.2 on 2026-04-02, v1.10.0 on 2026-04-16, v2.0.0-alpha.1 on 2026-05-21).
- Apparent update cadence is fairly frequent, roughly every 2 to 6 weeks across these recent updates, with a shift from maintenance (v1.9.2, v1.10.0) to a new major alpha (v2.0.0-alpha.1).
AI summary generated Today
Recent updates
v2.0.0-alpha.1
1 week agov2.0.0-alpha.1 makes major platform and packaging changes, including switching JavaScript packages to ESM-only. It also significantly adjusts worker and async execution internals and changes build outputs (for example, removal of prebuilt wasm target libraries). Additionally, the public TypeScript surface in @emnapi/core changes around worker initialization and plugin extensibility.
BreakingFeaturesv1.10.0
1 month agov1.10.0 focuses on fixing wasm memory growth behavior and improving JS-side TSFN (threadsafe function) coalescing. It also includes CI workflow restructuring and builds targeting LLVM 22. The core runtime changes revolve around external memory accounting and more accurate handling of shared/wasm memory state.
Breakingv1.9.2
2 months agov1.9.2 is a targeted maintenance release focused on enabling support for a 4GB maximum memory configuration. The release notes only mention this one change, but the code diff shows additional behavior adjustments around unsigned length/pointer handling and async worker resolution.
v1.9.1
2 months agov1.9.1 is a patch release that claims to include a fix related to Emscripten 5.0.3. The diff shows build workflow changes to use EM_VERSION 5.0.3 and a change in the Emscripten ESM library transform logic, plus routine version bumps across packages and the emnapi header.
v1.9.0
2 months agov1.9.0 focuses on stability fixes for emnapi's thread synchronization, plus an internal refactor of async work dispatch to reduce deadlocks when the main thread blocks. The release notes also document a rename of the experimental object-property creation API and the addition of a `requiredConfig` export to help consumers configure the required wasm toolchain flags.
BreakingFeaturesv1.8.1
4 months agov1.8.1 primarily adds support for Float16Array as a new TypedArray type in emnapi. The codebase also includes a few additional type and build-related adjustments that are not mentioned in the release notes.
Featuresv1.8.0
5 months agov1.8.0 introduces support for the experimental Node-API function node_api_set_prototype. The release notes only mention this one new API, while the code diff also includes additional header macro gating and several internal test adjustments.
Featuresv1.7.1
6 months agov1.7.1 introduces support for creating DataView instances from SharedArrayBuffer in napi_create_dataview, and it updates how the project enables or detects Node-API experimental behavior. The diff also shows multiple build and header-organization changes that could affect developers compiling against the public headers.
Featuresv1.7.0
7 months agov1.7.0 adds support for the Node-API method `napi_create_object_with_properties`. The release notes mention only this feature, but the code diff shows it is implemented as an experimental API and is gated behind `NAPI_EXPERIMENTAL` in the C headers.
Featuresv1.6.0
7 months agov1.6.0 adds experimental SharedArrayBuffer support to emnapi, including new N-API style entry points for detecting and creating SharedArrayBuffer instances. It also updates the native API header so napi_delete_reference uses node_api_basic_env, and adjusts CI/release workflow behavior for publishing.
BreakingFeatures