Advanced JavaScript code search: Abstract Syntax Tree analysis
summary
Proof‑of‑concept builds a JavaScript code search by parsing files with Babel or Acorn into ASTs, flattening nodes to an array and indexing name/type/kind/parentId into an Orama in‑memory full‑text index, so queries return exact locations (example: find a const named FS where parent type is VariableDeclarator). Babel shows ~50M downloads/week so parsing is practical, results return file positions reliably, and the demo suggests adding AI for pattern detection.
AI-written summary · about
chapters (7)
- 0:00JavaScript AST analysis intro
- 7:39JavaScript engines parsing
- 10:10What is an AST
- 13:23AST in tools
- 16:39Advanced AST code search
- 23:54AST meets AI
- 25:19Resources and closing
related talks
31mAST à la Vista, Baby
29mMy Little Parser: Tooling is Magic
29mAST: the Secret Weapon to Transform a Codebase
28mMaster the art of the AST and take control of your JS
33mAs Simple as an AST
43mMachine Powered Refactoring: Leverage AST's to Push Your Legacy Code (& the Web) Forward
38mThe magical land of AST's with babel, eslint and codemods
47mComputer, refactor my code!
