# What changed in napi-derive-backend

> 33 changes in napi-derive-backend 3 to 7 from its official release notes, upgrade guides and advisories: 1 security, 7 new APIs and options. Each one cited. Sources checked 2026-11-23. HTML: https://unstale.sh/cargo/napi-derive-backend/

To see which of these apply to a repository, run `npx @unstale/cli init` in it.

## napi-derive-backend 7

### New APIs and options

- Class members can use symbol_for keys. (7.0.0) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v7.0.0)
- Class members can use well-known symbol keys. (7.0.0) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v7.0.0)

### Fixes and other changes

- Fixes per-environment teardown for multi-load addons and prevents AsyncTask promises from leaking. (7.0.1) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v7.0.1)
- Avoids TS1016 errors in constructors. (7.0.0) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v7.0.0)
- Closures defined with define_class are freed. (7.0.0) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v7.0.0)
- Static flags are now honoured. (7.0.0) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v7.0.0)

## napi-derive-backend 6

### Security

- Classes marked with #[napi] have unforgeable identity via Node object type tags. (6.0.0) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v6.0.0)

### Tooling

- The CLI now supports non-threaded WASI targets. (6.1.0) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v6.1.0)

### Fixes and other changes

- Borrowed class arguments remain alive across AsyncTask and AsyncBlock. (6.1.6) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v6.1.6)
- Unadopted class values are dropped and the factory flag is reset when conversion fails. (6.1.6) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v6.1.6)
- Enum variants are exported as writable, enumerable, configurable properties. (6.1.5) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v6.1.5)
- Guards AsyncTask completion against environment teardown. (6.1.4) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v6.1.4)
- Aligns generated file formats. (6.1.3) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v6.1.3)
- The macro now recognizes fully qualified napi::Env as the special Env parameter. (6.1.3) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v6.1.3)
- Addons with live native code are no longer unloaded. (6.1.2) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v6.1.2)
- Non-Error rejections are preserved. (6.1.2) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v6.1.2)
- Add a teardown barrier for wasm. (6.1.2) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v6.1.2)
- Preserves the namespace when resolving cross-namespace type references. (6.1.1) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v6.1.1)
- Validation looks up constructors by js_name. (6.1.1) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v6.1.1)

## napi-derive-backend 5

### New APIs and options

- `To`/`FromNapiValue` implementations are added for `OsString`, `OsStr`, `Path` and `PathBuf`, enabling these types to be converted through napi. (5.1.0) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v5.1.0)
- Outlines field-error decoration for #[napi(object)]. (5.0.5) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v5.0.5)
- Adds the async_iterator macro attribute for napi. (5.0.0) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v5.0.0)

### Performance

- Object field raw property access was optimized. (5.1.1) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v5.1.1)

### Fixes and other changes

- The derive implementation defers borrowing the receiver until after argument conversion. (5.1.2) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v5.1.2)
- Only FnArgs unpacks a tuple to variadic parameters. (5.0.4) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v5.0.4)
- Preserves generator class methods. (5.0.3) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v5.0.3)
- Asterisks in comments are now escaped. (5.0.2) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v5.0.2)
- Fixed a memory leak in async functions. (5.0.1) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v5.0.1)

## napi-derive-backend 4

### New APIs and options

- A tracing feature was added for debug logging NAPI function calls. (4.0.0) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v4.0.0)

### Fixes and other changes

- Fixes the inability to use an optional parameter for a class setter. (4.0.1) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v4.0.1)
- Parentheses are added for function types. (4.0.0) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v4.0.0)

## napi-derive-backend 3

### New APIs and options

- Adds `discriminant_case` to allow changing the case of discriminants. (3.0.0) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v3.0.0)

### Fixes and other changes

- Fixed TypedArray type generation. (3.0.1) — [release notes](https://github.com/napi-rs/napi-rs/releases/tag/napi-derive-backend-v3.0.1)
