← 回集市
其他★ 16,356

ast-grep

按语法树搜索与改写代码(不是文本匹配),支持 20+ 语言。

怎么装 / 怎么用

ast-grep -p '$A && $A()' -l ts -r '$A?.()'

去 GitHub 看仓库