Sr Frontend in Zemoga and coo-organizer of Bogota.js
@nic_restrepo
Parsers & The abstract syntax tree
V8 - Chrome
SpiderMonkey - Firefox
Chackra - Edge
JavaScriptCore - Safari
var foo = 3 * 3;
[
{
"type": "Keyword",
"value": "var"
},
{
"type": "Identifier",
"value": "foo"
},
{
"type": "Punctuator",
"value": "="
},
{
"type": "numeric",
"value": "3"
},
{
"type": "Punctuator",
"value": "*"
},
{
"type": "numeric",
"value": "3"
},
{
"type": "Punctuator",
"value": ";"
}
]Β is a tree representation of the abstract syntactic structure of source code written in a programming language. Each node of the tree denotes a construct occurring in the source code.
DEMO, AST (ESLINT RULES)Β π
THANKS !!! π¨πΌβπ»