swc/crates/swc_ecma_parser/tests/tsc/tsxStatelessFunctionComponentOverload5.json
2022-03-22 07:54:08 +00:00

2960 lines
82 KiB
JSON

{
"type": "Module",
"span": {
"start": 131,
"end": 2014,
"ctxt": 0
},
"body": [
{
"type": "TsImportEqualsDeclaration",
"span": {
"start": 131,
"end": 162,
"ctxt": 0
},
"declare": false,
"isExport": false,
"isTypeOnly": false,
"id": {
"type": "Identifier",
"span": {
"start": 138,
"end": 143,
"ctxt": 0
},
"value": "React",
"optional": false
},
"moduleRef": {
"type": "TsExternalModuleReference",
"span": {
"start": 146,
"end": 162,
"ctxt": 0
},
"expression": {
"type": "StringLiteral",
"span": {
"start": 154,
"end": 161,
"ctxt": 0
},
"value": "react",
"raw": "'react'"
}
}
},
{
"type": "ExportDeclaration",
"span": {
"start": 164,
"end": 246,
"ctxt": 0
},
"declaration": {
"type": "TsInterfaceDeclaration",
"span": {
"start": 171,
"end": 246,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 181,
"end": 195,
"ctxt": 0
},
"value": "ClickableProps",
"optional": false
},
"declare": false,
"typeParams": null,
"extends": [],
"body": {
"type": "TsInterfaceBody",
"span": {
"start": 196,
"end": 246,
"ctxt": 0
},
"body": [
{
"type": "TsPropertySignature",
"span": {
"start": 202,
"end": 220,
"ctxt": 0
},
"readonly": false,
"key": {
"type": "Identifier",
"span": {
"start": 202,
"end": 210,
"ctxt": 0
},
"value": "children",
"optional": false
},
"computed": false,
"optional": true,
"init": null,
"params": [],
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 211,
"end": 219,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsKeywordType",
"span": {
"start": 213,
"end": 219,
"ctxt": 0
},
"kind": "string"
}
},
"typeParams": null
},
{
"type": "TsPropertySignature",
"span": {
"start": 225,
"end": 244,
"ctxt": 0
},
"readonly": false,
"key": {
"type": "Identifier",
"span": {
"start": 225,
"end": 234,
"ctxt": 0
},
"value": "className",
"optional": false
},
"computed": false,
"optional": true,
"init": null,
"params": [],
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 235,
"end": 243,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsKeywordType",
"span": {
"start": 237,
"end": 243,
"ctxt": 0
},
"kind": "string"
}
},
"typeParams": null
}
]
}
}
},
{
"type": "ExportDeclaration",
"span": {
"start": 248,
"end": 346,
"ctxt": 0
},
"declaration": {
"type": "TsInterfaceDeclaration",
"span": {
"start": 255,
"end": 346,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 265,
"end": 276,
"ctxt": 0
},
"value": "ButtonProps",
"optional": false
},
"declare": false,
"typeParams": null,
"extends": [
{
"type": "TsExpressionWithTypeArguments",
"span": {
"start": 285,
"end": 299,
"ctxt": 0
},
"expression": {
"type": "Identifier",
"span": {
"start": 285,
"end": 299,
"ctxt": 0
},
"value": "ClickableProps",
"optional": false
},
"typeArguments": null
}
],
"body": {
"type": "TsInterfaceBody",
"span": {
"start": 300,
"end": 346,
"ctxt": 0
},
"body": [
{
"type": "TsPropertySignature",
"span": {
"start": 306,
"end": 344,
"ctxt": 0
},
"readonly": false,
"key": {
"type": "Identifier",
"span": {
"start": 306,
"end": 313,
"ctxt": 0
},
"value": "onClick",
"optional": false
},
"computed": false,
"optional": false,
"init": null,
"params": [],
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 313,
"end": 343,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsTypeReference",
"span": {
"start": 315,
"end": 343,
"ctxt": 0
},
"typeName": {
"type": "TsQualifiedName",
"left": {
"type": "Identifier",
"span": {
"start": 315,
"end": 320,
"ctxt": 0
},
"value": "React",
"optional": false
},
"right": {
"type": "Identifier",
"span": {
"start": 321,
"end": 338,
"ctxt": 0
},
"value": "MouseEventHandler",
"optional": false
}
},
"typeParams": {
"type": "TsTypeParameterInstantiation",
"span": {
"start": 338,
"end": 343,
"ctxt": 0
},
"params": [
{
"type": "TsKeywordType",
"span": {
"start": 339,
"end": 342,
"ctxt": 0
},
"kind": "any"
}
]
}
}
},
"typeParams": null
}
]
}
}
},
{
"type": "ExportDeclaration",
"span": {
"start": 348,
"end": 417,
"ctxt": 0
},
"declaration": {
"type": "TsInterfaceDeclaration",
"span": {
"start": 355,
"end": 417,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 365,
"end": 374,
"ctxt": 0
},
"value": "LinkProps",
"optional": false
},
"declare": false,
"typeParams": null,
"extends": [
{
"type": "TsExpressionWithTypeArguments",
"span": {
"start": 383,
"end": 397,
"ctxt": 0
},
"expression": {
"type": "Identifier",
"span": {
"start": 383,
"end": 397,
"ctxt": 0
},
"value": "ClickableProps",
"optional": false
},
"typeArguments": null
}
],
"body": {
"type": "TsInterfaceBody",
"span": {
"start": 398,
"end": 417,
"ctxt": 0
},
"body": [
{
"type": "TsPropertySignature",
"span": {
"start": 404,
"end": 415,
"ctxt": 0
},
"readonly": false,
"key": {
"type": "Identifier",
"span": {
"start": 404,
"end": 406,
"ctxt": 0
},
"value": "to",
"optional": false
},
"computed": false,
"optional": false,
"init": null,
"params": [],
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 406,
"end": 414,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsKeywordType",
"span": {
"start": 408,
"end": 414,
"ctxt": 0
},
"kind": "string"
}
},
"typeParams": null
}
]
}
}
},
{
"type": "ExportDeclaration",
"span": {
"start": 419,
"end": 501,
"ctxt": 0
},
"declaration": {
"type": "TsInterfaceDeclaration",
"span": {
"start": 426,
"end": 501,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 436,
"end": 447,
"ctxt": 0
},
"value": "HyphenProps",
"optional": false
},
"declare": false,
"typeParams": null,
"extends": [
{
"type": "TsExpressionWithTypeArguments",
"span": {
"start": 456,
"end": 470,
"ctxt": 0
},
"expression": {
"type": "Identifier",
"span": {
"start": 456,
"end": 470,
"ctxt": 0
},
"value": "ClickableProps",
"optional": false
},
"typeArguments": null
}
],
"body": {
"type": "TsInterfaceBody",
"span": {
"start": 471,
"end": 501,
"ctxt": 0
},
"body": [
{
"type": "TsPropertySignature",
"span": {
"start": 477,
"end": 499,
"ctxt": 0
},
"readonly": false,
"key": {
"type": "StringLiteral",
"span": {
"start": 477,
"end": 490,
"ctxt": 0
},
"value": "data-format",
"raw": "\"data-format\""
},
"computed": false,
"optional": false,
"init": null,
"params": [],
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 490,
"end": 498,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsKeywordType",
"span": {
"start": 492,
"end": 498,
"ctxt": 0
},
"kind": "string"
}
},
"typeParams": null
}
]
}
}
},
{
"type": "VariableDeclaration",
"span": {
"start": 503,
"end": 534,
"ctxt": 0
},
"kind": "let",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 507,
"end": 533,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 507,
"end": 511,
"ctxt": 0
},
"value": "obj0",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "ObjectExpression",
"span": {
"start": 514,
"end": 533,
"ctxt": 0
},
"properties": [
{
"type": "KeyValueProperty",
"key": {
"type": "Identifier",
"span": {
"start": 520,
"end": 522,
"ctxt": 0
},
"value": "to",
"optional": false
},
"value": {
"type": "StringLiteral",
"span": {
"start": 524,
"end": 531,
"ctxt": 0
},
"value": "world",
"raw": "\"world\""
}
}
]
},
"definite": false
}
]
},
{
"type": "VariableDeclaration",
"span": {
"start": 536,
"end": 584,
"ctxt": 0
},
"kind": "let",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 540,
"end": 584,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 540,
"end": 544,
"ctxt": 0
},
"value": "obj1",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "ObjectExpression",
"span": {
"start": 547,
"end": 584,
"ctxt": 0
},
"properties": [
{
"type": "KeyValueProperty",
"key": {
"type": "Identifier",
"span": {
"start": 553,
"end": 561,
"ctxt": 0
},
"value": "children",
"optional": false
},
"value": {
"type": "StringLiteral",
"span": {
"start": 563,
"end": 567,
"ctxt": 0
},
"value": "hi",
"raw": "\"hi\""
}
},
{
"type": "KeyValueProperty",
"key": {
"type": "Identifier",
"span": {
"start": 573,
"end": 575,
"ctxt": 0
},
"value": "to",
"optional": false
},
"value": {
"type": "StringLiteral",
"span": {
"start": 577,
"end": 582,
"ctxt": 0
},
"value": "boo",
"raw": "\"boo\""
}
}
]
},
"definite": false
}
]
},
{
"type": "VariableDeclaration",
"span": {
"start": 586,
"end": 620,
"ctxt": 0
},
"kind": "let",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 590,
"end": 620,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 590,
"end": 594,
"ctxt": 0
},
"value": "obj2",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "ObjectExpression",
"span": {
"start": 597,
"end": 620,
"ctxt": 0
},
"properties": [
{
"type": "KeyValueProperty",
"key": {
"type": "Identifier",
"span": {
"start": 603,
"end": 610,
"ctxt": 0
},
"value": "onClick",
"optional": false
},
"value": {
"type": "ArrowFunctionExpression",
"span": {
"start": 612,
"end": 618,
"ctxt": 0
},
"params": [],
"body": {
"type": "BlockStatement",
"span": {
"start": 616,
"end": 618,
"ctxt": 0
},
"stmts": []
},
"async": false,
"generator": false,
"typeParameters": null,
"returnType": null
}
}
]
},
"definite": false
}
]
},
{
"type": "VariableDeclaration",
"span": {
"start": 622,
"end": 636,
"ctxt": 0
},
"kind": "let",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 626,
"end": 635,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 626,
"end": 630,
"ctxt": 0
},
"value": "obj3",
"optional": false,
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 630,
"end": 635,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsKeywordType",
"span": {
"start": 632,
"end": 635,
"ctxt": 0
},
"kind": "any"
}
}
},
"init": null,
"definite": false
}
]
},
{
"type": "ExportDeclaration",
"span": {
"start": 638,
"end": 704,
"ctxt": 0
},
"declaration": {
"type": "FunctionDeclaration",
"identifier": {
"type": "Identifier",
"span": {
"start": 654,
"end": 664,
"ctxt": 0
},
"value": "MainButton",
"optional": false
},
"declare": false,
"params": [
{
"type": "Parameter",
"span": {
"start": 665,
"end": 689,
"ctxt": 0
},
"decorators": [],
"pat": {
"type": "Identifier",
"span": {
"start": 665,
"end": 689,
"ctxt": 0
},
"value": "buttonProps",
"optional": false,
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 676,
"end": 689,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsTypeReference",
"span": {
"start": 678,
"end": 689,
"ctxt": 0
},
"typeName": {
"type": "Identifier",
"span": {
"start": 678,
"end": 689,
"ctxt": 0
},
"value": "ButtonProps",
"optional": false
},
"typeParams": null
}
}
}
}
],
"decorators": [],
"span": {
"start": 645,
"end": 704,
"ctxt": 0
},
"body": null,
"generator": false,
"async": false,
"typeParameters": null,
"returnType": {
"type": "TsTypeAnnotation",
"span": {
"start": 690,
"end": 703,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsTypeReference",
"span": {
"start": 692,
"end": 703,
"ctxt": 0
},
"typeName": {
"type": "TsQualifiedName",
"left": {
"type": "Identifier",
"span": {
"start": 692,
"end": 695,
"ctxt": 0
},
"value": "JSX",
"optional": false
},
"right": {
"type": "Identifier",
"span": {
"start": 696,
"end": 703,
"ctxt": 0
},
"value": "Element",
"optional": false
}
},
"typeParams": null
}
}
}
},
{
"type": "ExportDeclaration",
"span": {
"start": 705,
"end": 767,
"ctxt": 0
},
"declaration": {
"type": "FunctionDeclaration",
"identifier": {
"type": "Identifier",
"span": {
"start": 721,
"end": 731,
"ctxt": 0
},
"value": "MainButton",
"optional": false
},
"declare": false,
"params": [
{
"type": "Parameter",
"span": {
"start": 732,
"end": 752,
"ctxt": 0
},
"decorators": [],
"pat": {
"type": "Identifier",
"span": {
"start": 732,
"end": 752,
"ctxt": 0
},
"value": "linkProps",
"optional": false,
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 741,
"end": 752,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsTypeReference",
"span": {
"start": 743,
"end": 752,
"ctxt": 0
},
"typeName": {
"type": "Identifier",
"span": {
"start": 743,
"end": 752,
"ctxt": 0
},
"value": "LinkProps",
"optional": false
},
"typeParams": null
}
}
}
}
],
"decorators": [],
"span": {
"start": 712,
"end": 767,
"ctxt": 0
},
"body": null,
"generator": false,
"async": false,
"typeParameters": null,
"returnType": {
"type": "TsTypeAnnotation",
"span": {
"start": 753,
"end": 766,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsTypeReference",
"span": {
"start": 755,
"end": 766,
"ctxt": 0
},
"typeName": {
"type": "TsQualifiedName",
"left": {
"type": "Identifier",
"span": {
"start": 755,
"end": 758,
"ctxt": 0
},
"value": "JSX",
"optional": false
},
"right": {
"type": "Identifier",
"span": {
"start": 759,
"end": 766,
"ctxt": 0
},
"value": "Element",
"optional": false
}
},
"typeParams": null
}
}
}
},
{
"type": "ExportDeclaration",
"span": {
"start": 768,
"end": 834,
"ctxt": 0
},
"declaration": {
"type": "FunctionDeclaration",
"identifier": {
"type": "Identifier",
"span": {
"start": 784,
"end": 794,
"ctxt": 0
},
"value": "MainButton",
"optional": false
},
"declare": false,
"params": [
{
"type": "Parameter",
"span": {
"start": 795,
"end": 819,
"ctxt": 0
},
"decorators": [],
"pat": {
"type": "Identifier",
"span": {
"start": 795,
"end": 819,
"ctxt": 0
},
"value": "hyphenProps",
"optional": false,
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 806,
"end": 819,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsTypeReference",
"span": {
"start": 808,
"end": 819,
"ctxt": 0
},
"typeName": {
"type": "Identifier",
"span": {
"start": 808,
"end": 819,
"ctxt": 0
},
"value": "HyphenProps",
"optional": false
},
"typeParams": null
}
}
}
}
],
"decorators": [],
"span": {
"start": 775,
"end": 834,
"ctxt": 0
},
"body": null,
"generator": false,
"async": false,
"typeParameters": null,
"returnType": {
"type": "TsTypeAnnotation",
"span": {
"start": 820,
"end": 833,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsTypeReference",
"span": {
"start": 822,
"end": 833,
"ctxt": 0
},
"typeName": {
"type": "TsQualifiedName",
"left": {
"type": "Identifier",
"span": {
"start": 822,
"end": 825,
"ctxt": 0
},
"value": "JSX",
"optional": false
},
"right": {
"type": "Identifier",
"span": {
"start": 826,
"end": 833,
"ctxt": 0
},
"value": "Element",
"optional": false
}
},
"typeParams": null
}
}
}
},
{
"type": "ExportDeclaration",
"span": {
"start": 835,
"end": 1080,
"ctxt": 0
},
"declaration": {
"type": "FunctionDeclaration",
"identifier": {
"type": "Identifier",
"span": {
"start": 851,
"end": 861,
"ctxt": 0
},
"value": "MainButton",
"optional": false
},
"declare": false,
"params": [
{
"type": "Parameter",
"span": {
"start": 862,
"end": 906,
"ctxt": 0
},
"decorators": [],
"pat": {
"type": "Identifier",
"span": {
"start": 862,
"end": 906,
"ctxt": 0
},
"value": "props",
"optional": false,
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 867,
"end": 906,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsUnionType",
"span": {
"start": 869,
"end": 906,
"ctxt": 0
},
"types": [
{
"type": "TsTypeReference",
"span": {
"start": 869,
"end": 880,
"ctxt": 0
},
"typeName": {
"type": "Identifier",
"span": {
"start": 869,
"end": 880,
"ctxt": 0
},
"value": "ButtonProps",
"optional": false
},
"typeParams": null
},
{
"type": "TsTypeReference",
"span": {
"start": 883,
"end": 892,
"ctxt": 0
},
"typeName": {
"type": "Identifier",
"span": {
"start": 883,
"end": 892,
"ctxt": 0
},
"value": "LinkProps",
"optional": false
},
"typeParams": null
},
{
"type": "TsTypeReference",
"span": {
"start": 895,
"end": 906,
"ctxt": 0
},
"typeName": {
"type": "Identifier",
"span": {
"start": 895,
"end": 906,
"ctxt": 0
},
"value": "HyphenProps",
"optional": false
},
"typeParams": null
}
]
}
}
}
}
],
"decorators": [],
"span": {
"start": 842,
"end": 1080,
"ctxt": 0
},
"body": {
"type": "BlockStatement",
"span": {
"start": 921,
"end": 1080,
"ctxt": 0
},
"stmts": [
{
"type": "VariableDeclaration",
"span": {
"start": 927,
"end": 964,
"ctxt": 0
},
"kind": "const",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 933,
"end": 963,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 933,
"end": 942,
"ctxt": 0
},
"value": "linkProps",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "TsAsExpression",
"span": {
"start": 945,
"end": 963,
"ctxt": 0
},
"expression": {
"type": "Identifier",
"span": {
"start": 945,
"end": 950,
"ctxt": 0
},
"value": "props",
"optional": false
},
"typeAnnotation": {
"type": "TsTypeReference",
"span": {
"start": 954,
"end": 963,
"ctxt": 0
},
"typeName": {
"type": "Identifier",
"span": {
"start": 954,
"end": 963,
"ctxt": 0
},
"value": "LinkProps",
"optional": false
},
"typeParams": null
}
},
"definite": false
}
]
},
{
"type": "IfStatement",
"span": {
"start": 969,
"end": 1036,
"ctxt": 0
},
"test": {
"type": "MemberExpression",
"span": {
"start": 972,
"end": 984,
"ctxt": 0
},
"object": {
"type": "Identifier",
"span": {
"start": 972,
"end": 981,
"ctxt": 0
},
"value": "linkProps",
"optional": false
},
"property": {
"type": "Identifier",
"span": {
"start": 982,
"end": 984,
"ctxt": 0
},
"value": "to",
"optional": false
}
},
"consequent": {
"type": "BlockStatement",
"span": {
"start": 986,
"end": 1036,
"ctxt": 0
},
"stmts": [
{
"type": "ReturnStatement",
"span": {
"start": 996,
"end": 1030,
"ctxt": 0
},
"argument": {
"type": "CallExpression",
"span": {
"start": 1003,
"end": 1029,
"ctxt": 0
},
"callee": {
"type": "MemberExpression",
"span": {
"start": 1003,
"end": 1022,
"ctxt": 0
},
"object": {
"type": "ThisExpression",
"span": {
"start": 1003,
"end": 1007,
"ctxt": 0
}
},
"property": {
"type": "Identifier",
"span": {
"start": 1008,
"end": 1022,
"ctxt": 0
},
"value": "_buildMainLink",
"optional": false
}
},
"arguments": [
{
"spread": null,
"expression": {
"type": "Identifier",
"span": {
"start": 1023,
"end": 1028,
"ctxt": 0
},
"value": "props",
"optional": false
}
}
],
"typeArguments": null
}
}
]
},
"alternate": null
},
{
"type": "ReturnStatement",
"span": {
"start": 1042,
"end": 1078,
"ctxt": 0
},
"argument": {
"type": "CallExpression",
"span": {
"start": 1049,
"end": 1077,
"ctxt": 0
},
"callee": {
"type": "MemberExpression",
"span": {
"start": 1049,
"end": 1070,
"ctxt": 0
},
"object": {
"type": "ThisExpression",
"span": {
"start": 1049,
"end": 1053,
"ctxt": 0
}
},
"property": {
"type": "Identifier",
"span": {
"start": 1054,
"end": 1070,
"ctxt": 0
},
"value": "_buildMainButton",
"optional": false
}
},
"arguments": [
{
"spread": null,
"expression": {
"type": "Identifier",
"span": {
"start": 1071,
"end": 1076,
"ctxt": 0
},
"value": "props",
"optional": false
}
}
],
"typeArguments": null
}
}
]
},
"generator": false,
"async": false,
"typeParameters": null,
"returnType": {
"type": "TsTypeAnnotation",
"span": {
"start": 907,
"end": 920,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsTypeReference",
"span": {
"start": 909,
"end": 920,
"ctxt": 0
},
"typeName": {
"type": "TsQualifiedName",
"left": {
"type": "Identifier",
"span": {
"start": 909,
"end": 912,
"ctxt": 0
},
"value": "JSX",
"optional": false
},
"right": {
"type": "Identifier",
"span": {
"start": 913,
"end": 920,
"ctxt": 0
},
"value": "Element",
"optional": false
}
},
"typeParams": null
}
}
}
},
{
"type": "VariableDeclaration",
"span": {
"start": 1091,
"end": 1164,
"ctxt": 0
},
"kind": "const",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 1097,
"end": 1163,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 1097,
"end": 1099,
"ctxt": 0
},
"value": "b0",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "JSXElement",
"span": {
"start": 1102,
"end": 1163,
"ctxt": 0
},
"opening": {
"type": "JSXOpeningElement",
"name": {
"type": "Identifier",
"span": {
"start": 1103,
"end": 1113,
"ctxt": 0
},
"value": "MainButton",
"optional": false
},
"span": {
"start": 1102,
"end": 1148,
"ctxt": 0
},
"attributes": [
{
"type": "JSXAttribute",
"span": {
"start": 1114,
"end": 1129,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 1114,
"end": 1116,
"ctxt": 0
},
"value": "to",
"optional": false
},
"value": {
"type": "StringLiteral",
"span": {
"start": 1117,
"end": 1129,
"ctxt": 0
},
"value": "/some/path",
"raw": "'/some/path'"
}
},
{
"type": "JSXAttribute",
"span": {
"start": 1130,
"end": 1147,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 1130,
"end": 1137,
"ctxt": 0
},
"value": "onClick",
"optional": false
},
"value": {
"type": "JSXExpressionContainer",
"span": {
"start": 1138,
"end": 1147,
"ctxt": 0
},
"expression": {
"type": "ArrowFunctionExpression",
"span": {
"start": 1139,
"end": 1146,
"ctxt": 0
},
"params": [
{
"type": "Identifier",
"span": {
"start": 1140,
"end": 1141,
"ctxt": 0
},
"value": "e",
"optional": false,
"typeAnnotation": null
}
],
"body": {
"type": "BlockStatement",
"span": {
"start": 1144,
"end": 1146,
"ctxt": 0
},
"stmts": []
},
"async": false,
"generator": false,
"typeParameters": null,
"returnType": null
}
}
}
],
"selfClosing": false,
"typeArguments": null
},
"children": [
{
"type": "JSXText",
"span": {
"start": 1148,
"end": 1150,
"ctxt": 0
},
"value": "GO",
"raw": "GO"
}
],
"closing": {
"type": "JSXClosingElement",
"span": {
"start": 1150,
"end": 1163,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 1152,
"end": 1162,
"ctxt": 0
},
"value": "MainButton",
"optional": false
}
}
},
"definite": false
}
]
},
{
"type": "VariableDeclaration",
"span": {
"start": 1185,
"end": 1267,
"ctxt": 0
},
"kind": "const",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 1191,
"end": 1266,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 1191,
"end": 1193,
"ctxt": 0
},
"value": "b1",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "JSXElement",
"span": {
"start": 1196,
"end": 1266,
"ctxt": 0
},
"opening": {
"type": "JSXOpeningElement",
"name": {
"type": "Identifier",
"span": {
"start": 1197,
"end": 1207,
"ctxt": 0
},
"value": "MainButton",
"optional": false
},
"span": {
"start": 1196,
"end": 1242,
"ctxt": 0
},
"attributes": [
{
"type": "JSXAttribute",
"span": {
"start": 1208,
"end": 1231,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 1208,
"end": 1215,
"ctxt": 0
},
"value": "onClick",
"optional": false
},
"value": {
"type": "JSXExpressionContainer",
"span": {
"start": 1216,
"end": 1231,
"ctxt": 0
},
"expression": {
"type": "ArrowFunctionExpression",
"span": {
"start": 1217,
"end": 1230,
"ctxt": 0
},
"params": [
{
"type": "Identifier",
"span": {
"start": 1218,
"end": 1224,
"ctxt": 0
},
"value": "e",
"optional": false,
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 1219,
"end": 1224,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsKeywordType",
"span": {
"start": 1221,
"end": 1224,
"ctxt": 0
},
"kind": "any"
}
}
}
],
"body": {
"type": "BlockStatement",
"span": {
"start": 1228,
"end": 1230,
"ctxt": 0
},
"stmts": []
},
"async": false,
"generator": false,
"typeParameters": null,
"returnType": null
}
}
},
{
"type": "SpreadElement",
"spread": {
"start": 1233,
"end": 1236,
"ctxt": 0
},
"arguments": {
"type": "Identifier",
"span": {
"start": 1236,
"end": 1240,
"ctxt": 0
},
"value": "obj0",
"optional": false
}
}
],
"selfClosing": false,
"typeArguments": null
},
"children": [
{
"type": "JSXText",
"span": {
"start": 1242,
"end": 1253,
"ctxt": 0
},
"value": "Hello world",
"raw": "Hello world"
}
],
"closing": {
"type": "JSXClosingElement",
"span": {
"start": 1253,
"end": 1266,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 1255,
"end": 1265,
"ctxt": 0
},
"value": "MainButton",
"optional": false
}
}
},
"definite": false
}
]
},
{
"type": "VariableDeclaration",
"span": {
"start": 1288,
"end": 1343,
"ctxt": 0
},
"kind": "const",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 1294,
"end": 1342,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 1294,
"end": 1296,
"ctxt": 0
},
"value": "b2",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "JSXElement",
"span": {
"start": 1299,
"end": 1342,
"ctxt": 0
},
"opening": {
"type": "JSXOpeningElement",
"name": {
"type": "Identifier",
"span": {
"start": 1300,
"end": 1310,
"ctxt": 0
},
"value": "MainButton",
"optional": false
},
"span": {
"start": 1299,
"end": 1342,
"ctxt": 0
},
"attributes": [
{
"type": "SpreadElement",
"spread": {
"start": 1312,
"end": 1315,
"ctxt": 0
},
"arguments": {
"type": "ObjectExpression",
"span": {
"start": 1315,
"end": 1328,
"ctxt": 0
},
"properties": [
{
"type": "KeyValueProperty",
"key": {
"type": "Identifier",
"span": {
"start": 1316,
"end": 1318,
"ctxt": 0
},
"value": "to",
"optional": false
},
"value": {
"type": "StringLiteral",
"span": {
"start": 1320,
"end": 1327,
"ctxt": 0
},
"value": "10000",
"raw": "\"10000\""
}
}
]
}
},
{
"type": "SpreadElement",
"spread": {
"start": 1331,
"end": 1334,
"ctxt": 0
},
"arguments": {
"type": "Identifier",
"span": {
"start": 1334,
"end": 1338,
"ctxt": 0
},
"value": "obj2",
"optional": false
}
}
],
"selfClosing": true,
"typeArguments": null
},
"children": [],
"closing": null
},
"definite": false
}
]
},
{
"type": "VariableDeclaration",
"span": {
"start": 1363,
"end": 1434,
"ctxt": 0
},
"kind": "const",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 1369,
"end": 1433,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 1369,
"end": 1371,
"ctxt": 0
},
"value": "b3",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "JSXElement",
"span": {
"start": 1374,
"end": 1433,
"ctxt": 0
},
"opening": {
"type": "JSXOpeningElement",
"name": {
"type": "Identifier",
"span": {
"start": 1375,
"end": 1385,
"ctxt": 0
},
"value": "MainButton",
"optional": false
},
"span": {
"start": 1374,
"end": 1433,
"ctxt": 0
},
"attributes": [
{
"type": "SpreadElement",
"spread": {
"start": 1387,
"end": 1390,
"ctxt": 0
},
"arguments": {
"type": "ObjectExpression",
"span": {
"start": 1390,
"end": 1403,
"ctxt": 0
},
"properties": [
{
"type": "KeyValueProperty",
"key": {
"type": "Identifier",
"span": {
"start": 1391,
"end": 1393,
"ctxt": 0
},
"value": "to",
"optional": false
},
"value": {
"type": "StringLiteral",
"span": {
"start": 1395,
"end": 1402,
"ctxt": 0
},
"value": "10000",
"raw": "\"10000\""
}
}
]
}
},
{
"type": "SpreadElement",
"spread": {
"start": 1406,
"end": 1409,
"ctxt": 0
},
"arguments": {
"type": "ObjectExpression",
"span": {
"start": 1409,
"end": 1429,
"ctxt": 0
},
"properties": [
{
"type": "KeyValueProperty",
"key": {
"type": "Identifier",
"span": {
"start": 1410,
"end": 1417,
"ctxt": 0
},
"value": "onClick",
"optional": false
},
"value": {
"type": "ArrowFunctionExpression",
"span": {
"start": 1419,
"end": 1428,
"ctxt": 0
},
"params": [
{
"type": "Identifier",
"span": {
"start": 1420,
"end": 1421,
"ctxt": 0
},
"value": "k",
"optional": false,
"typeAnnotation": null
}
],
"body": {
"type": "BlockStatement",
"span": {
"start": 1426,
"end": 1428,
"ctxt": 0
},
"stmts": []
},
"async": false,
"generator": false,
"typeParameters": null,
"returnType": null
}
}
]
}
}
],
"selfClosing": true,
"typeArguments": null
},
"children": [],
"closing": null
},
"definite": false
}
]
},
{
"type": "VariableDeclaration",
"span": {
"start": 1454,
"end": 1493,
"ctxt": 0
},
"kind": "const",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 1460,
"end": 1492,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 1460,
"end": 1462,
"ctxt": 0
},
"value": "b4",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "JSXElement",
"span": {
"start": 1465,
"end": 1492,
"ctxt": 0
},
"opening": {
"type": "JSXOpeningElement",
"name": {
"type": "Identifier",
"span": {
"start": 1466,
"end": 1476,
"ctxt": 0
},
"value": "MainButton",
"optional": false
},
"span": {
"start": 1465,
"end": 1492,
"ctxt": 0
},
"attributes": [
{
"type": "SpreadElement",
"spread": {
"start": 1478,
"end": 1481,
"ctxt": 0
},
"arguments": {
"type": "Identifier",
"span": {
"start": 1481,
"end": 1485,
"ctxt": 0
},
"value": "obj3",
"optional": false
}
},
{
"type": "JSXAttribute",
"span": {
"start": 1487,
"end": 1489,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 1487,
"end": 1489,
"ctxt": 0
},
"value": "to",
"optional": false
},
"value": null
}
],
"selfClosing": true,
"typeArguments": null
},
"children": [],
"closing": null
},
"definite": false
}
]
},
{
"type": "VariableDeclaration",
"span": {
"start": 1583,
"end": 1648,
"ctxt": 0
},
"kind": "const",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 1589,
"end": 1647,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 1589,
"end": 1591,
"ctxt": 0
},
"value": "b5",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "JSXElement",
"span": {
"start": 1594,
"end": 1647,
"ctxt": 0
},
"opening": {
"type": "JSXOpeningElement",
"name": {
"type": "Identifier",
"span": {
"start": 1595,
"end": 1605,
"ctxt": 0
},
"value": "MainButton",
"optional": false
},
"span": {
"start": 1594,
"end": 1647,
"ctxt": 0
},
"attributes": [
{
"type": "SpreadElement",
"spread": {
"start": 1607,
"end": 1610,
"ctxt": 0
},
"arguments": {
"type": "ObjectExpression",
"span": {
"start": 1610,
"end": 1633,
"ctxt": 0
},
"properties": [
{
"type": "MethodProperty",
"key": {
"type": "Identifier",
"span": {
"start": 1612,
"end": 1619,
"ctxt": 0
},
"value": "onClick",
"optional": false
},
"params": [
{
"type": "Parameter",
"span": {
"start": 1620,
"end": 1626,
"ctxt": 0
},
"decorators": [],
"pat": {
"type": "Identifier",
"span": {
"start": 1620,
"end": 1626,
"ctxt": 0
},
"value": "e",
"optional": false,
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 1621,
"end": 1626,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsKeywordType",
"span": {
"start": 1623,
"end": 1626,
"ctxt": 0
},
"kind": "any"
}
}
}
}
],
"decorators": [],
"span": {
"start": 1612,
"end": 1631,
"ctxt": 0
},
"body": {
"type": "BlockStatement",
"span": {
"start": 1628,
"end": 1631,
"ctxt": 0
},
"stmts": []
},
"generator": false,
"async": false,
"typeParameters": null,
"returnType": null
}
]
}
},
{
"type": "SpreadElement",
"spread": {
"start": 1636,
"end": 1639,
"ctxt": 0
},
"arguments": {
"type": "Identifier",
"span": {
"start": 1639,
"end": 1643,
"ctxt": 0
},
"value": "obj0",
"optional": false
}
}
],
"selfClosing": true,
"typeArguments": null
},
"children": [],
"closing": null
},
"definite": false
}
]
},
{
"type": "VariableDeclaration",
"span": {
"start": 1743,
"end": 1810,
"ctxt": 0
},
"kind": "const",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 1749,
"end": 1809,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 1749,
"end": 1751,
"ctxt": 0
},
"value": "b6",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "JSXElement",
"span": {
"start": 1754,
"end": 1809,
"ctxt": 0
},
"opening": {
"type": "JSXOpeningElement",
"name": {
"type": "Identifier",
"span": {
"start": 1755,
"end": 1765,
"ctxt": 0
},
"value": "MainButton",
"optional": false
},
"span": {
"start": 1754,
"end": 1809,
"ctxt": 0
},
"attributes": [
{
"type": "SpreadElement",
"spread": {
"start": 1767,
"end": 1770,
"ctxt": 0
},
"arguments": {
"type": "ObjectExpression",
"span": {
"start": 1770,
"end": 1791,
"ctxt": 0
},
"properties": [
{
"type": "MethodProperty",
"key": {
"type": "Identifier",
"span": {
"start": 1772,
"end": 1779,
"ctxt": 0
},
"value": "onClick",
"optional": false
},
"params": [
{
"type": "Parameter",
"span": {
"start": 1780,
"end": 1786,
"ctxt": 0
},
"decorators": [],
"pat": {
"type": "Identifier",
"span": {
"start": 1780,
"end": 1786,
"ctxt": 0
},
"value": "e",
"optional": false,
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 1781,
"end": 1786,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsKeywordType",
"span": {
"start": 1783,
"end": 1786,
"ctxt": 0
},
"kind": "any"
}
}
}
}
],
"decorators": [],
"span": {
"start": 1772,
"end": 1789,
"ctxt": 0
},
"body": {
"type": "BlockStatement",
"span": {
"start": 1787,
"end": 1789,
"ctxt": 0
},
"stmts": []
},
"generator": false,
"async": false,
"typeParameters": null,
"returnType": null
}
]
}
},
{
"type": "JSXAttribute",
"span": {
"start": 1793,
"end": 1806,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 1793,
"end": 1801,
"ctxt": 0
},
"value": "children",
"optional": false
},
"value": {
"type": "JSXExpressionContainer",
"span": {
"start": 1802,
"end": 1806,
"ctxt": 0
},
"expression": {
"type": "NumericLiteral",
"span": {
"start": 1803,
"end": 1805,
"ctxt": 0
},
"value": 10.0
}
}
}
],
"selfClosing": true,
"typeArguments": null
},
"children": [],
"closing": null
},
"definite": false
}
]
},
{
"type": "VariableDeclaration",
"span": {
"start": 1853,
"end": 1933,
"ctxt": 0
},
"kind": "const",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 1859,
"end": 1932,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 1859,
"end": 1861,
"ctxt": 0
},
"value": "b7",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "JSXElement",
"span": {
"start": 1864,
"end": 1932,
"ctxt": 0
},
"opening": {
"type": "JSXOpeningElement",
"name": {
"type": "Identifier",
"span": {
"start": 1865,
"end": 1875,
"ctxt": 0
},
"value": "MainButton",
"optional": false
},
"span": {
"start": 1864,
"end": 1932,
"ctxt": 0
},
"attributes": [
{
"type": "SpreadElement",
"spread": {
"start": 1877,
"end": 1880,
"ctxt": 0
},
"arguments": {
"type": "ObjectExpression",
"span": {
"start": 1880,
"end": 1901,
"ctxt": 0
},
"properties": [
{
"type": "MethodProperty",
"key": {
"type": "Identifier",
"span": {
"start": 1882,
"end": 1889,
"ctxt": 0
},
"value": "onClick",
"optional": false
},
"params": [
{
"type": "Parameter",
"span": {
"start": 1890,
"end": 1896,
"ctxt": 0
},
"decorators": [],
"pat": {
"type": "Identifier",
"span": {
"start": 1890,
"end": 1896,
"ctxt": 0
},
"value": "e",
"optional": false,
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 1891,
"end": 1896,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsKeywordType",
"span": {
"start": 1893,
"end": 1896,
"ctxt": 0
},
"kind": "any"
}
}
}
}
],
"decorators": [],
"span": {
"start": 1882,
"end": 1899,
"ctxt": 0
},
"body": {
"type": "BlockStatement",
"span": {
"start": 1897,
"end": 1899,
"ctxt": 0
},
"stmts": []
},
"generator": false,
"async": false,
"typeParameters": null,
"returnType": null
}
]
}
},
{
"type": "JSXAttribute",
"span": {
"start": 1903,
"end": 1919,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 1903,
"end": 1911,
"ctxt": 0
},
"value": "children",
"optional": false
},
"value": {
"type": "StringLiteral",
"span": {
"start": 1912,
"end": 1919,
"ctxt": 0
},
"value": "hello",
"raw": "\"hello\""
}
},
{
"type": "JSXAttribute",
"span": {
"start": 1920,
"end": 1929,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 1920,
"end": 1929,
"ctxt": 0
},
"value": "className",
"optional": false
},
"value": null
}
],
"selfClosing": true,
"typeArguments": null
},
"children": [],
"closing": null
},
"definite": false
}
]
},
{
"type": "VariableDeclaration",
"span": {
"start": 1976,
"end": 2014,
"ctxt": 0
},
"kind": "const",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 1982,
"end": 2013,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 1982,
"end": 1984,
"ctxt": 0
},
"value": "b8",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "JSXElement",
"span": {
"start": 1987,
"end": 2013,
"ctxt": 0
},
"opening": {
"type": "JSXOpeningElement",
"name": {
"type": "Identifier",
"span": {
"start": 1988,
"end": 1998,
"ctxt": 0
},
"value": "MainButton",
"optional": false
},
"span": {
"start": 1987,
"end": 2013,
"ctxt": 0
},
"attributes": [
{
"type": "JSXAttribute",
"span": {
"start": 1999,
"end": 2010,
"ctxt": 0
},
"name": {
"type": "Identifier",
"span": {
"start": 1999,
"end": 2010,
"ctxt": 0
},
"value": "data-format",
"optional": false
},
"value": null
}
],
"selfClosing": true,
"typeArguments": null
},
"children": [],
"closing": null
},
"definite": false
}
]
}
],
"interpreter": null
}