unstale

npm / emnapi

emnapi

What changed in emnapi 1, from its official release notes, upgrade guides and advisories. Also covers @emnapi/core, @emnapi/runtime. Sources checked 2026-10-19.

2 breaking1 security6 new APIs and options6 behavior and defaults8 fixes and other

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

npx @unstale/cli init

@unstale/cli on npm

emnapi 123 changes

Breaking changes 2

Security 1

  • Fixes a data race and use-after-free, and fixes thread-safe functions not working in JavaScript-based async_work workers.

    1.9.0release notes

New APIs and options 6

  • Adds napi_create_external_sharedarraybuffer.

    1.11.0release notes

  • Adds requiredConfig to the package entry, exposing required configuration hints such as clang.wasmld.

    1.9.0release notes

  • Adds support for Float16Array.

    1.8.1release notes

  • Adds the node_api_set_prototype API.

    1.8.0release notes

  • Adds the napi_create_object_with_properties method.

    1.7.0release notes

  • Added the SharedArrayBuffer API.

    1.6.0release notes

Behavior and default changes 6

  • Supports SharedArrayBuffer in napi_create_typedarray.

    1.11.0release notes

  • Allows maximum memory of 4GB.

    1.9.2release notes

  • The libraries now include libuv symbols.

    1.9.0release notes

  • Spawning an async worker in JavaScript uses pthread_create instead of maintaining a separate worker pool.

    1.9.0release notes

  • napi_create_dataview supports SharedArrayBuffer.

    1.7.1release notes

  • Changed napi_delete_reference to use node_api_basic_env.

    1.6.0release notes

Fixes and other changes 8

  • Deferred state is defined as own properties.

    1.11.3release notes

  • Memory views are refreshed after unshared memory growth.

    1.11.3release notes

  • Refreshes a stale shared memory buffer before atomic access.

    1.11.1release notes

  • Calling napi_adjust_external_memory no longer grows wasm memory.

    1.10.0release notes

  • Wasm memory is updated earlier for views, addressing the shared-memory grow issue.

    1.10.0release notes

  • Dispatches the async work queue in shared memory to avoid deadlocks when the main thread waits for queued work to start.

    1.9.0release notes

  • Fixes pthread_create not working in JavaScript-based async_work workers.

    1.9.0release notes

  • The finalizer executes after the queue drains when the thread-safe function is aborted.

    1.9.0release notes