feat(unstable): add JS linting plugin infrastructure (#27416)

This PR extracts the core part of
https://github.com/denoland/deno/pull/27203 to make it easier to review
and land in parts.

It contains:
-  The JS plugin code the deserializes and walks the buffer
- The Rust portion to serialize SWC to the buffer format (a bunch of
nodes are still todos, but imo these can land anytime later)
- Basic lint plugin types, without the AST node types to make this PR
easier to review
- Added more code comments to explain the format etc.


More fixes and changes will be done in follow-up PRs.

---------

Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
This commit is contained in:
Marvin Hagemeister 2024-12-21 00:58:03 +01:00 committed by GitHub
parent 77e1af79bd
commit 26425a137b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
15 changed files with 5499 additions and 3 deletions

View file

@ -526,6 +526,9 @@ const NOT_IMPORTED_OPS = [
// Used in jupyter API
"op_base64_encode",
// Used in the lint API
"op_lint_create_serialized_ast",
// Related to `Deno.test()` API
"op_test_event_step_result_failed",
"op_test_event_step_result_ignored",