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

148 lines
3.6 KiB
JSON

{
"type": "Script",
"span": {
"start": 174,
"end": 279,
"ctxt": 0
},
"body": [
{
"type": "VariableDeclaration",
"span": {
"start": 174,
"end": 205,
"ctxt": 0
},
"kind": "var",
"declare": true,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 186,
"end": 204,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 186,
"end": 187,
"ctxt": 0
},
"value": "$",
"optional": false,
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 187,
"end": 204,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsTypeLiteral",
"span": {
"start": 189,
"end": 204,
"ctxt": 0
},
"members": [
{
"type": "TsMethodSignature",
"span": {
"start": 191,
"end": 202,
"ctxt": 0
},
"readonly": false,
"key": {
"type": "Identifier",
"span": {
"start": 191,
"end": 194,
"ctxt": 0
},
"value": "foo",
"optional": false
},
"computed": false,
"optional": false,
"params": [],
"typeAnn": {
"type": "TsTypeAnnotation",
"span": {
"start": 196,
"end": 202,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsKeywordType",
"span": {
"start": 198,
"end": 202,
"ctxt": 0
},
"kind": "void"
}
},
"typeParams": null
}
]
}
}
},
"init": null,
"definite": false
}
]
},
{
"type": "ExpressionStatement",
"span": {
"start": 271,
"end": 279,
"ctxt": 0
},
"expression": {
"type": "CallExpression",
"span": {
"start": 271,
"end": 278,
"ctxt": 0
},
"callee": {
"type": "MemberExpression",
"span": {
"start": 271,
"end": 276,
"ctxt": 0
},
"object": {
"type": "Identifier",
"span": {
"start": 271,
"end": 272,
"ctxt": 0
},
"value": "$",
"optional": false
},
"property": {
"type": "Identifier",
"span": {
"start": 273,
"end": 276,
"ctxt": 0
},
"value": "foo",
"optional": false
}
},
"arguments": [],
"typeArguments": null
}
}
],
"interpreter": null
}