You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
svelte/test/parser/samples/if-block-elseif/output.json

102 lines
1.7 KiB

8 years ago
{
"hash": 985817334,
8 years ago
"html": {
"start": 0,
"end": 93,
"type": "Fragment",
"children": [
{
"start": 0,
"end": 93,
"type": "IfBlock",
"expression": {
"type": "BinaryExpression",
8 years ago
"start": 6,
"end": 12,
"left": {
"type": "Identifier",
8 years ago
"start": 6,
"end": 7,
"name": "x"
},
"operator": ">",
8 years ago
"right": {
"type": "Literal",
8 years ago
"start": 10,
"end": 12,
"value": 10,
"raw": "10"
}
},
"children": [
{
"start": 16,
"end": 43,
"type": "Element",
"name": "p",
"attributes": [],
"children": [
{
"start": 19,
"end": 39,
"type": "Text",
"data": "x is greater than 10"
}
]
}
],
"else": {
"start": 60,
"end": 86,
"type": "ElseBlock",
"children": [
{
"start": 60,
"end": 93,
"type": "IfBlock",
"elseif": true,
"expression": {
"type": "BinaryExpression",
8 years ago
"start": 53,
"end": 58,
"left": {
"type": "Identifier",
8 years ago
"start": 53,
"end": 54,
"name": "x"
},
"operator": "<",
8 years ago
"right": {
"type": "Literal",
8 years ago
"start": 57,
"end": 58,
"value": 5,
"raw": "5"
}
},
"children": [
{
"start": 62,
"end": 85,
"type": "Element",
"name": "p",
"attributes": [],
"children": [
{
"start": 65,
"end": 81,
"type": "Text",
"data": "x is less than 5"
}
]
}
]
}
]
}
}
]
},
"css": null,
"js": null
}