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

275 lines
5.7 KiB
JSON

{
"type": "Module",
"span": {
"start": 140,
"end": 361,
"ctxt": 0
},
"body": [
{
"type": "ImportDeclaration",
"span": {
"start": 140,
"end": 162,
"ctxt": 0
},
"specifiers": [
{
"type": "ImportDefaultSpecifier",
"span": {
"start": 147,
"end": 150,
"ctxt": 0
},
"local": {
"type": "Identifier",
"span": {
"start": 147,
"end": 150,
"ctxt": 0
},
"value": "foo",
"optional": false
}
}
],
"source": {
"type": "StringLiteral",
"span": {
"start": 156,
"end": 161,
"ctxt": 0
},
"value": "./b",
"hasEscape": false,
"kind": {
"type": "normal",
"containsQuote": true
}
},
"typeOnly": false,
"asserts": null
},
{
"type": "ExportDefaultDeclaration",
"span": {
"start": 163,
"end": 190,
"ctxt": 0
},
"decl": {
"type": "ClassExpression",
"identifier": {
"type": "Identifier",
"span": {
"start": 184,
"end": 187,
"ctxt": 0
},
"value": "Foo",
"optional": false
},
"span": {
"start": 178,
"end": 190,
"ctxt": 0
},
"decorators": [],
"body": [],
"superClass": null,
"isAbstract": false,
"typeParams": null,
"superTypeParams": null,
"implements": []
}
},
{
"type": "ExpressionStatement",
"span": {
"start": 191,
"end": 197,
"ctxt": 0
},
"expression": {
"type": "CallExpression",
"span": {
"start": 191,
"end": 196,
"ctxt": 0
},
"callee": {
"type": "Identifier",
"span": {
"start": 191,
"end": 194,
"ctxt": 0
},
"value": "foo",
"optional": false
},
"arguments": [],
"typeArguments": null
}
},
{
"type": "ImportDeclaration",
"span": {
"start": 222,
"end": 244,
"ctxt": 0
},
"specifiers": [
{
"type": "ImportDefaultSpecifier",
"span": {
"start": 229,
"end": 232,
"ctxt": 0
},
"local": {
"type": "Identifier",
"span": {
"start": 229,
"end": 232,
"ctxt": 0
},
"value": "Foo",
"optional": false
}
}
],
"source": {
"type": "StringLiteral",
"span": {
"start": 238,
"end": 243,
"ctxt": 0
},
"value": "./a",
"hasEscape": false,
"kind": {
"type": "normal",
"containsQuote": true
}
},
"typeOnly": false,
"asserts": null
},
{
"type": "ExportDefaultDeclaration",
"span": {
"start": 245,
"end": 289,
"ctxt": 0
},
"decl": {
"type": "FunctionExpression",
"identifier": {
"type": "Identifier",
"span": {
"start": 269,
"end": 272,
"ctxt": 0
},
"value": "foo",
"optional": false
},
"params": [],
"decorators": [],
"span": {
"start": 260,
"end": 289,
"ctxt": 0
},
"body": {
"type": "BlockStatement",
"span": {
"start": 275,
"end": 289,
"ctxt": 0
},
"stmts": [
{
"type": "ExpressionStatement",
"span": {
"start": 277,
"end": 287,
"ctxt": 0
},
"expression": {
"type": "NewExpression",
"span": {
"start": 277,
"end": 286,
"ctxt": 0
},
"callee": {
"type": "Identifier",
"span": {
"start": 281,
"end": 284,
"ctxt": 0
},
"value": "Foo",
"optional": false
},
"arguments": [],
"typeArguments": null
}
}
]
},
"generator": false,
"async": false,
"typeParameters": null,
"returnType": null
}
},
{
"type": "ExpressionStatement",
"span": {
"start": 347,
"end": 361,
"ctxt": 0
},
"expression": {
"type": "CallExpression",
"span": {
"start": 347,
"end": 360,
"ctxt": 0
},
"callee": {
"type": "Import",
"span": {
"start": 347,
"end": 353,
"ctxt": 0
}
},
"arguments": [
{
"spread": null,
"expression": {
"type": "StringLiteral",
"span": {
"start": 354,
"end": 359,
"ctxt": 0
},
"value": "./a",
"hasEscape": false,
"kind": {
"type": "normal",
"containsQuote": true
}
}
}
],
"typeArguments": null
}
}
],
"interpreter": null
}