Commit graph

7 commits

Author SHA1 Message Date
forehalo
2467b7139b
Introduce #[napi] procedural macro to automation development boilerplate (#696)
* napi procedural macro for basic rust/JavaScript types
* introduce the `compat-mode` for `napi` and `napi-derive` crates for backward compatible
* remove #[inline] and let compiler to decide the inline behavior
* cli now can produce the `.d.ts` file for native binding
* many tests and example for the new procedural macro

Co-authored-by: LongYinan <lynweklm@gmail.com>
2021-09-23 01:29:09 +08:00
LongYinan
f0b8c5da07
fix(napi): do not call release tsfn in Drop when ref count is 0 2021-03-31 21:31:37 +08:00
LongYinan
f46aa1f67a
fix(napi): throw JavaScript error in tsfn rather than rust thread panic 2021-01-25 12:11:12 +08:00
LongYinan
bb5e1f4286
feat(napi): implement create_reference/get_reference_value 2020-12-18 00:07:24 +08:00
LongYinan
eb5f4931bd
feat(napi): impl Clone and Drop for ThreadSafeFunction, return Status from ThreadSafeFunction::call 2020-11-11 16:51:11 +08:00
LongYinan
feced6ed52
chore: upgrade deps and fix type-check error 2020-08-24 18:22:48 +08:00
LongYinan
100ad98407
refactor(test_module): migrate tests to TypeScript 2020-08-24 16:55:54 +08:00
Renamed from test_module/__test__/napi4/threadsafe_function.spec.js (Browse further)