swc/crates/swc_ecma_parser/tests/tsc/library-reference-1.json

148 lines
3.6 KiB
JSON
Raw Normal View History

{
"type": "Script",
"span": {
"start": 196,
"end": 302,
"ctxt": 0
},
"body": [
{
"type": "VariableDeclaration",
"span": {
"start": 196,
"end": 227,
"ctxt": 0
},
"kind": "var",
"declare": true,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 208,
"end": 226,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 208,
"end": 209,
"ctxt": 0
},
"value": "$",
"optional": false,
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 209,
"end": 226,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsTypeLiteral",
"span": {
"start": 211,
"end": 226,
"ctxt": 0
},
"members": [
{
"type": "TsMethodSignature",
"span": {
"start": 213,
"end": 224,
"ctxt": 0
},
"readonly": false,
"key": {
"type": "Identifier",
"span": {
"start": 213,
"end": 216,
"ctxt": 0
},
"value": "foo",
"optional": false
},
"computed": false,
"optional": false,
"params": [],
"typeAnn": {
"type": "TsTypeAnnotation",
"span": {
"start": 218,
"end": 224,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsKeywordType",
"span": {
"start": 220,
"end": 224,
"ctxt": 0
},
"kind": "void"
}
},
"typeParams": null
}
]
}
}
},
"init": null,
"definite": false
}
]
},
{
"type": "ExpressionStatement",
"span": {
"start": 294,
"end": 302,
"ctxt": 0
},
"expression": {
"type": "CallExpression",
"span": {
"start": 294,
"end": 301,
"ctxt": 0
},
"callee": {
"type": "MemberExpression",
"span": {
"start": 294,
"end": 299,
"ctxt": 0
},
"object": {
"type": "Identifier",
"span": {
"start": 294,
"end": 295,
"ctxt": 0
},
"value": "$",
"optional": false
},
"property": {
"type": "Identifier",
"span": {
"start": 296,
"end": 299,
"ctxt": 0
},
"value": "foo",
"optional": false
}
},
"arguments": [],
"typeArguments": null
}
}
],
"interpreter": null
}