oxc/napi/parser
burlinchen 38e7351a91
chore(napi): Refactor async parsing functions to remove tokio dependency (#4049)
Resolves #4044
- Added `use napi::{bindgen_prelude::AsyncTask, Task}` to handle async
tasks without tokio.
- Introduced `ResolveTask` struct implementing `Task` for asynchronous
parsing.
- Replaced `parse_sync` function implementation with `parse_with_return`
to reuse code.
- Refactored `parse_async` to use `AsyncTask` and `ResolveTask` for
async parsing.
- Removed tokio dependency by avoiding `tokio::spawn` and using
`AsyncTask` for async operations.

This refactor enhances code readability and removes the dependency on
tokio, streamlining the async task handling within the napi framework.
2024-07-04 20:31:19 +08:00
..
src chore(napi): Refactor async parsing functions to remove tokio dependency (#4049) 2024-07-04 20:31:19 +08:00
build.rs refactor: change @oxidation-compiler/napi to oxc-parser (#1209) 2023-11-10 06:17:05 +00:00
Cargo.toml chore(napi): Refactor async parsing functions to remove tokio dependency (#4049) 2024-07-04 20:31:19 +08:00
index.d.ts fix(napi/parser): typescript types for Comment is out of order (#3646) 2024-06-13 00:20:26 +08:00
index.js feat(napi/parser): remove experimental flexbuffer api (#2957) 2024-04-13 14:59:31 +08:00
package.json feat(napi): isolated-declaration (#3718) 2024-06-17 13:06:00 +00:00
parse.bench.mjs fix(tasks): reduce variance of NAPI benchmarks (#2780) 2024-03-21 16:21:44 +00:00
pnpm-lock.yaml feat(napi/parser): remove experimental flexbuffer api (#2957) 2024-04-13 14:59:31 +08:00
test.mjs feat(napi): return comments (#2469) 2024-02-21 22:43:40 +08:00
test_module_lexer.mjs New tool: oxc_module_lexer (#2650) 2024-03-09 23:23:55 +08:00