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

323 lines
6.8 KiB
JSON

{
"type": "Module",
"span": {
"start": 89,
"end": 364,
"ctxt": 0
},
"body": [
{
"type": "ExportDeclaration",
"span": {
"start": 89,
"end": 111,
"ctxt": 0
},
"declaration": {
"type": "TsInterfaceDeclaration",
"span": {
"start": 96,
"end": 111,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 106,
"end": 107,
"ctxt": 0
},
"value": "I",
"optional": false
},
"declare": false,
"typeParams": null,
"extends": [],
"body": {
"type": "TsInterfaceBody",
"span": {
"start": 108,
"end": 111,
"ctxt": 0
},
"body": []
}
}
},
{
"type": "ExportNamedDeclaration",
"span": {
"start": 132,
"end": 181,
"ctxt": 0
},
"specifiers": [],
"source": {
"type": "StringLiteral",
"span": {
"start": 152,
"end": 157,
"ctxt": 0
},
"value": "./0",
"raw": "'./0'"
},
"typeOnly": true,
"asserts": {
"type": "ObjectExpression",
"span": {
"start": 165,
"end": 181,
"ctxt": 0
},
"properties": [
{
"type": "KeyValueProperty",
"key": {
"type": "Identifier",
"span": {
"start": 167,
"end": 171,
"ctxt": 0
},
"value": "type",
"optional": false
},
"value": {
"type": "StringLiteral",
"span": {
"start": 173,
"end": 179,
"ctxt": 0
},
"value": "json",
"raw": "\"json\""
}
}
]
}
},
{
"type": "ExportNamedDeclaration",
"span": {
"start": 182,
"end": 234,
"ctxt": 0
},
"specifiers": [
{
"type": "ExportSpecifier",
"span": {
"start": 196,
"end": 197,
"ctxt": 0
},
"orig": {
"type": "Identifier",
"span": {
"start": 196,
"end": 197,
"ctxt": 0
},
"value": "I",
"optional": false
},
"exported": null,
"isTypeOnly": false
}
],
"source": {
"type": "StringLiteral",
"span": {
"start": 205,
"end": 210,
"ctxt": 0
},
"value": "./0",
"raw": "'./0'"
},
"typeOnly": true,
"asserts": {
"type": "ObjectExpression",
"span": {
"start": 218,
"end": 234,
"ctxt": 0
},
"properties": [
{
"type": "KeyValueProperty",
"key": {
"type": "Identifier",
"span": {
"start": 220,
"end": 224,
"ctxt": 0
},
"value": "type",
"optional": false
},
"value": {
"type": "StringLiteral",
"span": {
"start": 226,
"end": 232,
"ctxt": 0
},
"value": "json",
"raw": "\"json\""
}
}
]
}
},
{
"type": "ImportDeclaration",
"span": {
"start": 255,
"end": 308,
"ctxt": 0
},
"specifiers": [
{
"type": "ImportSpecifier",
"span": {
"start": 269,
"end": 270,
"ctxt": 0
},
"local": {
"type": "Identifier",
"span": {
"start": 269,
"end": 270,
"ctxt": 0
},
"value": "I",
"optional": false
},
"imported": null,
"isTypeOnly": false
}
],
"source": {
"type": "StringLiteral",
"span": {
"start": 278,
"end": 283,
"ctxt": 0
},
"value": "./0",
"raw": "'./0'"
},
"typeOnly": true,
"asserts": {
"type": "ObjectExpression",
"span": {
"start": 292,
"end": 308,
"ctxt": 0
},
"properties": [
{
"type": "KeyValueProperty",
"key": {
"type": "Identifier",
"span": {
"start": 294,
"end": 298,
"ctxt": 0
},
"value": "type",
"optional": false
},
"value": {
"type": "StringLiteral",
"span": {
"start": 300,
"end": 306,
"ctxt": 0
},
"value": "json",
"raw": "\"json\""
}
}
]
}
},
{
"type": "ImportDeclaration",
"span": {
"start": 309,
"end": 364,
"ctxt": 0
},
"specifiers": [
{
"type": "ImportNamespaceSpecifier",
"span": {
"start": 321,
"end": 329,
"ctxt": 0
},
"local": {
"type": "Identifier",
"span": {
"start": 326,
"end": 329,
"ctxt": 0
},
"value": "foo",
"optional": false
}
}
],
"source": {
"type": "StringLiteral",
"span": {
"start": 335,
"end": 340,
"ctxt": 0
},
"value": "./0",
"raw": "'./0'"
},
"typeOnly": true,
"asserts": {
"type": "ObjectExpression",
"span": {
"start": 348,
"end": 364,
"ctxt": 0
},
"properties": [
{
"type": "KeyValueProperty",
"key": {
"type": "Identifier",
"span": {
"start": 350,
"end": 354,
"ctxt": 0
},
"value": "type",
"optional": false
},
"value": {
"type": "StringLiteral",
"span": {
"start": 356,
"end": 362,
"ctxt": 0
},
"value": "json",
"raw": "\"json\""
}
}
]
}
}
],
"interpreter": null
}