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

127 lines
2.6 KiB
JSON

{
"type": "Module",
"span": {
"start": 24,
"end": 110,
"ctxt": 0
},
"body": [
{
"type": "ExportDefaultDeclaration",
"span": {
"start": 24,
"end": 83,
"ctxt": 0
},
"decl": {
"type": "FunctionExpression",
"identifier": {
"type": "Identifier",
"span": {
"start": 48,
"end": 56,
"ctxt": 0
},
"value": "someFunc",
"optional": false
},
"params": [],
"decorators": [],
"span": {
"start": 39,
"end": 83,
"ctxt": 0
},
"body": {
"type": "BlockStatement",
"span": {
"start": 59,
"end": 83,
"ctxt": 0
},
"stmts": [
{
"type": "ReturnStatement",
"span": {
"start": 65,
"end": 81,
"ctxt": 0
},
"argument": {
"type": "StringLiteral",
"span": {
"start": 72,
"end": 80,
"ctxt": 0
},
"value": "hello!",
"raw": "'hello!'"
}
}
]
},
"generator": false,
"async": false,
"typeParameters": null,
"returnType": null
}
},
{
"type": "ExpressionStatement",
"span": {
"start": 85,
"end": 110,
"ctxt": 0
},
"expression": {
"type": "AssignmentExpression",
"span": {
"start": 85,
"end": 109,
"ctxt": 0
},
"operator": "=",
"left": {
"type": "MemberExpression",
"span": {
"start": 85,
"end": 102,
"ctxt": 0
},
"object": {
"type": "Identifier",
"span": {
"start": 85,
"end": 93,
"ctxt": 0
},
"value": "someFunc",
"optional": false
},
"property": {
"type": "Identifier",
"span": {
"start": 94,
"end": 102,
"ctxt": 0
},
"value": "someProp",
"optional": false
}
},
"right": {
"type": "StringLiteral",
"span": {
"start": 105,
"end": 109,
"ctxt": 0
},
"value": "yo",
"raw": "'yo'"
}
}
}
],
"interpreter": null
}