487 Commits

Author SHA1 Message Date
LongYinan
cf0465f390
chore(sys): add back non dyn-symbols behavior (#3045) 2025-12-02 16:46:42 +08:00
LongYinan
54a9654fae
fix(napi-derive): add paren for function types (#3044) 2025-12-02 14:56:17 +08:00
renovate[bot]
337abca4b1
chore(deps): update dependency @oxc-node/core to ^0.0.35 (#3042)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-12-01 11:42:13 +00:00
LongYinan
a10be50edb
fix(napi): shutdown runtime at env cleanup on windows (#3026) 2025-11-25 17:31:09 +08:00
LongYinan
8a60cd0f64
build(napi): fix tsdown config (#3010) 2025-11-10 11:42:38 +08:00
renovate[bot]
8bca68faa0
chore(deps): update dependency @oxc-node/core to ^0.0.34 (#3013)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-11-09 21:18:57 +00:00
renovate[bot]
4b8cce20b1
chore(deps): update dependency @oxc-node/core to ^0.0.33 (#3012)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-11-09 13:20:39 +00:00
LongYinan
25c159c500
fix(napi-derive): TypedArray typegen (#3005) 2025-11-07 22:47:15 +08:00
LongYinan
2a34f77272
fix(napi): TypedArraySlice creation (#3004) 2025-11-07 21:22:48 +08:00
renovate[bot]
e2a4ee6548
chore(deps): update dependency electron to v39 (#2979)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-10-28 23:03:01 +08:00
LongYinan
c388c120cf
fix(cli): remove createRequire in cjs binding (#2976) 2025-10-24 17:19:28 +08:00
LongYinan
d9498f5cec
fix(napi): stop ref error object in wasm targets (#2975) 2025-10-24 09:36:59 +08:00
renovate[bot]
657aab3ce9
chore(deps): update vitest monorepo to v4 (major) (#2971) 2025-10-23 17:15:30 +08:00
LongYinan
4c5bf78ab4
test: re-enable worker_threads tests on Windows (#2974) 2025-10-23 16:34:13 +08:00
LongYinan
01485ff423
fix(napi): do not invoke process.report on Windows (#2972) 2025-10-23 14:18:30 +08:00
khj809
694db41895
feat(napi-derive): add discriminant_case to allow changing case of discriminant (#2960) 2025-10-23 10:25:17 +08:00
LongYinan
656bdca927
refactor(napi-derive): make typegen easier to read (#2956) 2025-10-11 14:46:38 +08:00
LongYinan
69b8f096fd
fix(wasm-runtime): node:events polyfill on browser (#2954) 2025-10-10 22:08:33 +08:00
LongYinan
8f40ebd206
fix(napi): cleanup memory issues (#2949) 2025-10-05 19:35:20 +08:00
renovate[bot]
60b4befad1
chore(deps): lock file maintenance (#2944)
* chore(deps): lock file maintenance

* ignore bench

* fix test

* fix cache key

* fix bundle

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: LongYinan <lynweklm@gmail.com>
2025-10-03 20:57:21 +08:00
richerfu
9df9f890f7
feat(napi): add on_abort for AbortSignal (#2942)
* feat(napi): add on_abort for AbortSignal

* chore: upgrade example code

* fix: fix lint error

* fix: fix lint error

* Update examples/napi/src/task.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update crates/napi/src/bindgen_runtime/js_values/task.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* fmt

---------

Co-authored-by: LongYinan <lynweklm@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-10-03 16:14:32 +08:00
renovate[bot]
f4b771a22d
chore(deps): update dependency cross-env to v10.1.0 (#2941)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-29 18:08:14 +00:00
LongYinan
38b0b42592
chore: fix rust 1.90 behavior (#2932) 2025-09-19 19:44:42 +08:00
LongYinan
8120ca0ac4
chore(cli): throw error if wasi file not found when NAPI_RS_FORCE_WASI=error (#2919)
* chore(cli): throw error if wasi file not found when NAPI_RS_FORCE_WASI=error

* update snapshot
2025-09-11 16:29:05 +08:00
SkyBird
807f579796
feat(cli): add support for loongarch64-unknown-linux-gnu (#2887)
* feat(target): add support for loongarch64-unknown-linux-gnu

* docs(README): update platform support status

* Update cli/src/utils/target.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update .github/workflows/test-release.yaml

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: LongYinan <lynweklm@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-09-09 23:29:22 +08:00
LongYinan
08869f5e7f
fix(napi): node_api_create_external_string_utf16 on wasm (#2912) 2025-09-08 22:37:33 +08:00
Valentin Semirulnik
841ddf4231
fix(cli): NAPI_RS_NATIVE_LIBRARY_PATH usage (#2907)
* return value for NAPI_RS_NATIVE_LIBRARY_PATH branch

* update example

---------

Co-authored-by: LongYinan <lynweklm@gmail.com>
2025-09-08 14:23:30 +08:00
LongYinan
3894db5e42
fix(napi): JsStringUtf8 memory leak (#2911) 2025-09-08 13:45:17 +08:00
LongYinan
484ca281dd
feat(napi): implement from_static on JsStringLatin1 and JsStringUtf16 (#2908) 2025-09-05 12:48:41 +08:00
renovate[bot]
3c1a64f261
chore(deps): update dependency electron to v38 (#2904)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-04 16:12:47 +08:00
LongYinan
07380dfe49
feat(napi): support external JsStringLatin1 and JsStringUtf16 (#2898) 2025-09-01 10:40:40 +08:00
lghuahua
9d338543b9
chore(napi): extends the Set types interoperability (#2875) 2025-08-15 19:12:46 -07:00
LongYinan
cf5807f9f9
fix(napi-derive): codegen issue for &'env [u8] param (#2881) 2025-08-15 05:18:51 -07:00
LongYinan
364e81648b
fix(cli): generate next method on Iterator (#2864)
* fix(cli): generate next method on Iterator

* update snapshot
2025-08-10 19:00:03 +08:00
LongYinan
bcef141990
fix(napi-derive): comments idents regression (#2857) 2025-08-09 23:02:07 +08:00
renovate[bot]
fb4b878212
chore(deps): update dependency @oxc-node/core to ^0.0.32 (#2855)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-08-08 17:14:08 +00:00
LongYinan
b47efee028
fix(cli): wrong condition for the native binding version check (#2853) 2025-08-08 23:03:44 +08:00
LongYinan
eef8221421
fix(cli): don't enforce version check (#2849) 2025-08-08 15:31:55 +08:00
LongYinan
dca00683d8
fix(napi): handle the return_if_invalid for Array param (#2846)
* fix(napi): handle the return_if_invalid for Array param

* Update crates/backend/src/codegen/fn.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update crates/backend/src/codegen/fn.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-08-08 15:10:43 +08:00
Mikaël Francoeur
83389a186b
feat(napi): add ScopeGenerator trait (#2831)
* add lifetime to iterator

* Add ScopedIterator

* fix type gen

* Clippy fix

---------

Co-authored-by: LongYinan <lynweklm@gmail.com>
2025-08-07 21:44:01 +08:00
Mikaël Francoeur
88fca29e3b
feat: make generator an iterator (#2784)
* make the generator an iterator

* add JSDoc for generators

* prevent naming conflicts

* add JSDoc struct

* update snapshot

* clippy

* Update typedef

* update fmt

* Apply code review

* test compatible

---------

Co-authored-by: LongYinan <lynweklm@gmail.com>
2025-08-07 08:03:37 +00:00
LongYinan
1e30088198
fix(wasm-runtime): avoid wasm-util from tree shaking by rollup (#2810)
* fix(wasm-runtime): avoid wasm-util from tree shaking by rollup

* fix filename
2025-08-07 12:55:48 +08:00
LongYinan
ce4699025b
chore(napi): align the subsystem target triple parsing (#2838) 2025-08-07 12:55:05 +08:00
LongYinan
310581a5f8
feat(cli): validate the native binding versions (#2837) 2025-08-07 11:58:56 +08:00
cddf31fbad
test(napi): add more tests for Error.cause support (#2835) 2025-08-07 10:33:10 +08:00
7f5013eee3
feat(napi): add Error.cause support to napi::Error (#2829)
Co-authored-by: LongYinan <lynweklm@gmail.com>
2025-08-05 12:53:36 +08:00
LongYinan
e175512d43
fix(napi): async task finally is not called (#2824) 2025-08-01 15:05:08 +08:00
LongYinan
10416f1b43
fix(napi): relax the lifetime restriction in PromiseRaw callbacks (#2819) 2025-07-31 09:51:10 +08:00
renovate[bot]
642b5aba1c
chore(deps): update dependency cross-env to v10 (#2811)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-07-30 11:10:02 +08:00
bde407ddab
fix(napi-derive): generate types for threadsafe_function with WEAK=true correctly (#2813) 2025-07-30 00:24:15 +08:00