刘道玉 AI 工作坊
随笔 研究 专题 工作坊 关于 RSS

常见javascript解析器

2022-10-22

如果对编译器或者语言编译技术感兴趣,可以研究一些JavaScript解析器。

常见的javascript解析器(JavaScript parser)列表

terser

A JavaScript mangler/compressor toolkit for ES6+.

jsep

jsep: A Tiny JavaScript Expression Parser

jsep is a simple expression parser written in JavaScript. It can parse JavaScript expressions but not operations. The difference between expressions and operations is akin to the difference between a cell in an Excel spreadsheet vs. a proper JavaScript program.

slimit

limIt is a JavaScript minifier written in Python. It compiles JavaScript into more compact code so that it downloads and runs faster.

SlimIt also provides a library that includes a JavaScript parser, lexer, pretty printer and a tree visitor.

uglify-js

相关资源:

https://github.com/mishoo

http://lisperator.net/

Esprima

相关资源:

https://ariya.io/about

https://github.com/ariya

acorn

相关资源:

https://marijnhaverbeke.nl/

https://github.com/marijnh

@babel/parser

espree

相关资源:

https://github.com/nzakas

https://humanwhocodes.com/

TypeScript

sucrase

相关资源:

https://github.com/alangpierce

swc

相关资源:

https://github.com/kdy1

https://kdy1.github.io/

esbuild

相关资源:

https://github.com/evanw

http://madebyevan.com/

recast

相关资源:

https://github.com/benjamn

https://www.quora.com/profile/Ben-Newman

jscodeshift

相关资源:

https://github.com/fkling

https://felix-kling.de/

esprit

A JavaScript parser written in Rust.

ASTExplorer

pyjsparser

Fast JavaScript parser - manual translation of esprima.js to python. Takes 1 second to parse whole angular.js library so parsing speed is about 100k characters per second which makes it the fastest and most comprehensible JavaScript parser for python out there.

其他的相关解析器

css.js

A lightweight, battle tested, fast, css parser in JavaScript

  • 技术汇总
北漂的日子(十六)
立场
订阅 · 外部站点 · 行业资料 · 全部文章
© 2026 刘道玉 AI 工作坊
京ICP备16032693号