denoland / deno_ast

Source text parsing, lexing, and AST related functionality for Deno
https://crates.io/crates/deno_ast
MIT License
148 stars 45 forks source link

Provide web assembly mod #120

Closed timreichen closed 1 year ago

timreichen commented 1 year ago

Could a web assembly mod be provided like deno_doc does? This would be really useful for tools in deno_std.

Ref: https://github.com/denoland/deno_std/pull/2820#issuecomment-1295212385

dsherret commented 1 year ago

This would probably be hard to maintain and slow. I'd recommend instead sending the string to Wasm, then parsing with this crate there, doing the analysis, then returning the result back to javascript. That's what I do in dnt.