oxc/napi
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
..
parser chore(napi): Refactor async parsing functions to remove tokio dependency (#4049) 2024-07-04 20:31:19 +08:00
transform Release crates v0.16.3 (#4013) 2024-07-02 12:47:29 +08:00
.gitignore feat(napi): isolated-declaration (#3718) 2024-06-17 13:06:00 +00:00