swc/crates/swc_ecma_parser/tests/tsc/libReferenceNoLib.json

462 lines
9.9 KiB
JSON

{
"type": "Module",
"span": {
"start": 169,
"end": 503,
"ctxt": 0
},
"body": [
{
"type": "TsInterfaceDeclaration",
"span": {
"start": 169,
"end": 189,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 179,
"end": 185,
"ctxt": 0
},
"value": "Object",
"optional": false
},
"declare": false,
"typeParams": null,
"extends": [],
"body": {
"type": "TsInterfaceBody",
"span": {
"start": 186,
"end": 189,
"ctxt": 0
},
"body": []
}
},
{
"type": "TsInterfaceDeclaration",
"span": {
"start": 190,
"end": 212,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 200,
"end": 205,
"ctxt": 0
},
"value": "Array",
"optional": false
},
"declare": false,
"typeParams": {
"type": "TsTypeParameterDeclaration",
"span": {
"start": 205,
"end": 208,
"ctxt": 0
},
"parameters": [
{
"type": "TsTypeParameter",
"span": {
"start": 206,
"end": 207,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 206,
"end": 207,
"ctxt": 0
},
"value": "T",
"optional": false
},
"in": false,
"out": false,
"constraint": null,
"default": null
}
]
},
"extends": [],
"body": {
"type": "TsInterfaceBody",
"span": {
"start": 209,
"end": 212,
"ctxt": 0
},
"body": []
}
},
{
"type": "TsInterfaceDeclaration",
"span": {
"start": 213,
"end": 233,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 223,
"end": 229,
"ctxt": 0
},
"value": "String",
"optional": false
},
"declare": false,
"typeParams": null,
"extends": [],
"body": {
"type": "TsInterfaceBody",
"span": {
"start": 230,
"end": 233,
"ctxt": 0
},
"body": []
}
},
{
"type": "TsInterfaceDeclaration",
"span": {
"start": 234,
"end": 255,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 244,
"end": 251,
"ctxt": 0
},
"value": "Boolean",
"optional": false
},
"declare": false,
"typeParams": null,
"extends": [],
"body": {
"type": "TsInterfaceBody",
"span": {
"start": 252,
"end": 255,
"ctxt": 0
},
"body": []
}
},
{
"type": "TsInterfaceDeclaration",
"span": {
"start": 256,
"end": 276,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 266,
"end": 272,
"ctxt": 0
},
"value": "Number",
"optional": false
},
"declare": false,
"typeParams": null,
"extends": [],
"body": {
"type": "TsInterfaceBody",
"span": {
"start": 273,
"end": 276,
"ctxt": 0
},
"body": []
}
},
{
"type": "TsInterfaceDeclaration",
"span": {
"start": 277,
"end": 299,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 287,
"end": 295,
"ctxt": 0
},
"value": "Function",
"optional": false
},
"declare": false,
"typeParams": null,
"extends": [],
"body": {
"type": "TsInterfaceBody",
"span": {
"start": 296,
"end": 299,
"ctxt": 0
},
"body": []
}
},
{
"type": "TsInterfaceDeclaration",
"span": {
"start": 300,
"end": 320,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 310,
"end": 316,
"ctxt": 0
},
"value": "RegExp",
"optional": false
},
"declare": false,
"typeParams": null,
"extends": [],
"body": {
"type": "TsInterfaceBody",
"span": {
"start": 317,
"end": 320,
"ctxt": 0
},
"body": []
}
},
{
"type": "TsInterfaceDeclaration",
"span": {
"start": 321,
"end": 345,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 331,
"end": 341,
"ctxt": 0
},
"value": "IArguments",
"optional": false
},
"declare": false,
"typeParams": null,
"extends": [],
"body": {
"type": "TsInterfaceBody",
"span": {
"start": 342,
"end": 345,
"ctxt": 0
},
"body": []
}
},
{
"type": "ExportDeclaration",
"span": {
"start": 399,
"end": 454,
"ctxt": 0
},
"declaration": {
"type": "TsInterfaceDeclaration",
"span": {
"start": 406,
"end": 454,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 424,
"end": 435,
"ctxt": 0
},
"value": "HTMLElement",
"optional": false
},
"declare": true,
"typeParams": null,
"extends": [],
"body": {
"type": "TsInterfaceBody",
"span": {
"start": 436,
"end": 454,
"ctxt": 0
},
"body": [
{
"type": "TsPropertySignature",
"span": {
"start": 438,
"end": 452,
"ctxt": 0
},
"readonly": false,
"key": {
"type": "Identifier",
"span": {
"start": 438,
"end": 443,
"ctxt": 0
},
"value": "field",
"optional": false
},
"computed": false,
"optional": false,
"init": null,
"params": [],
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 443,
"end": 451,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsKeywordType",
"span": {
"start": 445,
"end": 451,
"ctxt": 0
},
"kind": "string"
}
},
"typeParams": null
}
]
}
}
},
{
"type": "ExportDeclaration",
"span": {
"start": 455,
"end": 503,
"ctxt": 0
},
"declaration": {
"type": "VariableDeclaration",
"span": {
"start": 462,
"end": 503,
"ctxt": 0
},
"kind": "const",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 468,
"end": 502,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 468,
"end": 472,
"ctxt": 0
},
"value": "elem",
"optional": false,
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 472,
"end": 485,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsTypeReference",
"span": {
"start": 474,
"end": 485,
"ctxt": 0
},
"typeName": {
"type": "Identifier",
"span": {
"start": 474,
"end": 485,
"ctxt": 0
},
"value": "HTMLElement",
"optional": false
},
"typeParams": null
}
}
},
"init": {
"type": "ObjectExpression",
"span": {
"start": 488,
"end": 502,
"ctxt": 0
},
"properties": [
{
"type": "KeyValueProperty",
"key": {
"type": "Identifier",
"span": {
"start": 490,
"end": 495,
"ctxt": 0
},
"value": "field",
"optional": false
},
"value": {
"type": "StringLiteral",
"span": {
"start": 497,
"end": 500,
"ctxt": 0
},
"value": "a",
"raw": "'a'"
}
}
]
},
"definite": false
}
]
}
}
],
"interpreter": null
}