{ "type": "Script", "span": { "start": 142, "end": 858, "ctxt": 0 }, "body": [ { "type": "ClassDeclaration", "identifier": { "type": "Identifier", "span": { "start": 148, "end": 157, "ctxt": 0 }, "value": "Rectangle", "optional": false }, "declare": false, "span": { "start": 142, "end": 228, "ctxt": 0 }, "decorators": [], "body": [ { "type": "Constructor", "span": { "start": 164, "end": 226, "ctxt": 0 }, "key": { "type": "Identifier", "span": { "start": 164, "end": 175, "ctxt": 0 }, "value": "constructor", "optional": false }, "params": [], "body": { "type": "BlockStatement", "span": { "start": 178, "end": 226, "ctxt": 0 }, "stmts": [ { "type": "ExpressionStatement", "span": { "start": 188, "end": 220, "ctxt": 0 }, "expression": { "type": "CallExpression", "span": { "start": 188, "end": 219, "ctxt": 0 }, "callee": { "type": "MemberExpression", "span": { "start": 188, "end": 199, "ctxt": 0 }, "object": { "type": "Identifier", "span": { "start": 188, "end": 195, "ctxt": 0 }, "value": "console", "optional": false }, "property": { "type": "Identifier", "span": { "start": 196, "end": 199, "ctxt": 0 }, "value": "log", "optional": false } }, "arguments": [ { "spread": null, "expression": { "type": "StringLiteral", "span": { "start": 200, "end": 218, "ctxt": 0 }, "value": "I'm a rectangle!", "hasEscape": false, "kind": { "type": "normal", "containsQuote": true } } } ], "typeArguments": null } } ] }, "accessibility": null, "isOptional": false } ], "superClass": null, "isAbstract": false, "typeParams": null, "superTypeParams": null, "implements": [] }, { "type": "ExpressionStatement", "span": { "start": 230, "end": 261, "ctxt": 0 }, "expression": { "type": "AssignmentExpression", "span": { "start": 230, "end": 260, "ctxt": 0 }, "operator": "=", "left": { "type": "MemberExpression", "span": { "start": 230, "end": 244, "ctxt": 0 }, "object": { "type": "Identifier", "span": { "start": 230, "end": 236, "ctxt": 0 }, "value": "module", "optional": false }, "property": { "type": "Identifier", "span": { "start": 237, "end": 244, "ctxt": 0 }, "value": "exports", "optional": false } }, "right": { "type": "ObjectExpression", "span": { "start": 247, "end": 260, "ctxt": 0 }, "properties": [ { "type": "Identifier", "span": { "start": 249, "end": 258, "ctxt": 0 }, "value": "Rectangle", "optional": false } ] } } }, { "type": "VariableDeclaration", "span": { "start": 285, "end": 328, "ctxt": 0 }, "kind": "const", "declare": false, "declarations": [ { "type": "VariableDeclarator", "span": { "start": 291, "end": 327, "ctxt": 0 }, "id": { "type": "ObjectPattern", "span": { "start": 291, "end": 302, "ctxt": 0 }, "properties": [ { "type": "AssignmentPatternProperty", "span": { "start": 292, "end": 301, "ctxt": 0 }, "key": { "type": "Identifier", "span": { "start": 292, "end": 301, "ctxt": 0 }, "value": "Rectangle", "optional": false }, "value": null } ], "optional": false, "typeAnnotation": null }, "init": { "type": "CallExpression", "span": { "start": 305, "end": 327, "ctxt": 0 }, "callee": { "type": "Identifier", "span": { "start": 305, "end": 312, "ctxt": 0 }, "value": "require", "optional": false }, "arguments": [ { "spread": null, "expression": { "type": "StringLiteral", "span": { "start": 313, "end": 326, "ctxt": 0 }, "value": "./rectangle", "hasEscape": false, "kind": { "type": "normal", "containsQuote": true } } } ], "typeArguments": null }, "definite": false } ] }, { "type": "ClassDeclaration", "identifier": { "type": "Identifier", "span": { "start": 336, "end": 342, "ctxt": 0 }, "value": "Render", "optional": false }, "declare": false, "span": { "start": 330, "end": 678, "ctxt": 0 }, "decorators": [], "body": [ { "type": "Constructor", "span": { "start": 349, "end": 475, "ctxt": 0 }, "key": { "type": "Identifier", "span": { "start": 349, "end": 360, "ctxt": 0 }, "value": "constructor", "optional": false }, "params": [], "body": { "type": "BlockStatement", "span": { "start": 363, "end": 475, "ctxt": 0 }, "stmts": [ { "type": "ExpressionStatement", "span": { "start": 451, "end": 469, "ctxt": 0 }, "expression": { "type": "AssignmentExpression", "span": { "start": 451, "end": 468, "ctxt": 0 }, "operator": "=", "left": { "type": "MemberExpression", "span": { "start": 451, "end": 463, "ctxt": 0 }, "object": { "type": "ThisExpression", "span": { "start": 451, "end": 455, "ctxt": 0 } }, "property": { "type": "Identifier", "span": { "start": 456, "end": 463, "ctxt": 0 }, "value": "objects", "optional": false } }, "right": { "type": "ArrayExpression", "span": { "start": 466, "end": 468, "ctxt": 0 }, "elements": [] } } } ] }, "accessibility": null, "isOptional": false }, { "type": "ClassMethod", "span": { "start": 565, "end": 676, "ctxt": 0 }, "key": { "type": "Identifier", "span": { "start": 565, "end": 577, "ctxt": 0 }, "value": "addRectangle", "optional": false }, "function": { "params": [], "decorators": [], "span": { "start": 565, "end": 676, "ctxt": 0 }, "body": { "type": "BlockStatement", "span": { "start": 580, "end": 676, "ctxt": 0 }, "stmts": [ { "type": "VariableDeclaration", "span": { "start": 590, "end": 618, "ctxt": 0 }, "kind": "const", "declare": false, "declarations": [ { "type": "VariableDeclarator", "span": { "start": 596, "end": 617, "ctxt": 0 }, "id": { "type": "Identifier", "span": { "start": 596, "end": 599, "ctxt": 0 }, "value": "obj", "optional": false, "typeAnnotation": null }, "init": { "type": "NewExpression", "span": { "start": 602, "end": 617, "ctxt": 0 }, "callee": { "type": "Identifier", "span": { "start": 606, "end": 615, "ctxt": 0 }, "value": "Rectangle", "optional": false }, "arguments": [], "typeArguments": null }, "definite": false } ] }, { "type": "ExpressionStatement", "span": { "start": 627, "end": 650, "ctxt": 0 }, "expression": { "type": "CallExpression", "span": { "start": 627, "end": 649, "ctxt": 0 }, "callee": { "type": "MemberExpression", "span": { "start": 627, "end": 644, "ctxt": 0 }, "object": { "type": "MemberExpression", "span": { "start": 627, "end": 639, "ctxt": 0 }, "object": { "type": "ThisExpression", "span": { "start": 627, "end": 631, "ctxt": 0 } }, "property": { "type": "Identifier", "span": { "start": 632, "end": 639, "ctxt": 0 }, "value": "objects", "optional": false } }, "property": { "type": "Identifier", "span": { "start": 640, "end": 644, "ctxt": 0 }, "value": "push", "optional": false } }, "arguments": [ { "spread": null, "expression": { "type": "Identifier", "span": { "start": 645, "end": 648, "ctxt": 0 }, "value": "obj", "optional": false } } ], "typeArguments": null } }, { "type": "ReturnStatement", "span": { "start": 659, "end": 670, "ctxt": 0 }, "argument": { "type": "Identifier", "span": { "start": 666, "end": 669, "ctxt": 0 }, "value": "obj", "optional": false } } ] }, "generator": false, "async": false, "typeParameters": null, "returnType": null }, "kind": "method", "isStatic": false, "accessibility": null, "isAbstract": false, "isOptional": false, "isOverride": false } ], "superClass": null, "isAbstract": false, "typeParams": null, "superTypeParams": null, "implements": [] }, { "type": "ExpressionStatement", "span": { "start": 680, "end": 708, "ctxt": 0 }, "expression": { "type": "AssignmentExpression", "span": { "start": 680, "end": 707, "ctxt": 0 }, "operator": "=", "left": { "type": "MemberExpression", "span": { "start": 680, "end": 694, "ctxt": 0 }, "object": { "type": "Identifier", "span": { "start": 680, "end": 686, "ctxt": 0 }, "value": "module", "optional": false }, "property": { "type": "Identifier", "span": { "start": 687, "end": 694, "ctxt": 0 }, "value": "exports", "optional": false } }, "right": { "type": "ObjectExpression", "span": { "start": 697, "end": 707, "ctxt": 0 }, "properties": [ { "type": "Identifier", "span": { "start": 699, "end": 705, "ctxt": 0 }, "value": "Render", "optional": false } ] } } }, { "type": "VariableDeclaration", "span": { "start": 731, "end": 767, "ctxt": 0 }, "kind": "const", "declare": false, "declarations": [ { "type": "VariableDeclarator", "span": { "start": 737, "end": 766, "ctxt": 0 }, "id": { "type": "ObjectPattern", "span": { "start": 737, "end": 745, "ctxt": 0 }, "properties": [ { "type": "AssignmentPatternProperty", "span": { "start": 738, "end": 744, "ctxt": 0 }, "key": { "type": "Identifier", "span": { "start": 738, "end": 744, "ctxt": 0 }, "value": "Render", "optional": false }, "value": null } ], "optional": false, "typeAnnotation": null }, "init": { "type": "CallExpression", "span": { "start": 748, "end": 766, "ctxt": 0 }, "callee": { "type": "Identifier", "span": { "start": 748, "end": 755, "ctxt": 0 }, "value": "require", "optional": false }, "arguments": [ { "spread": null, "expression": { "type": "StringLiteral", "span": { "start": 756, "end": 765, "ctxt": 0 }, "value": "./index", "hasEscape": false, "kind": { "type": "normal", "containsQuote": true } } } ], "typeArguments": null }, "definite": false } ] }, { "type": "VariableDeclaration", "span": { "start": 768, "end": 794, "ctxt": 0 }, "kind": "let", "declare": false, "declarations": [ { "type": "VariableDeclarator", "span": { "start": 772, "end": 793, "ctxt": 0 }, "id": { "type": "Identifier", "span": { "start": 772, "end": 778, "ctxt": 0 }, "value": "render", "optional": false, "typeAnnotation": null }, "init": { "type": "NewExpression", "span": { "start": 781, "end": 793, "ctxt": 0 }, "callee": { "type": "Identifier", "span": { "start": 785, "end": 791, "ctxt": 0 }, "value": "Render", "optional": false }, "arguments": [], "typeArguments": null }, "definite": false } ] }, { "type": "ExpressionStatement", "span": { "start": 796, "end": 818, "ctxt": 0 }, "expression": { "type": "CallExpression", "span": { "start": 796, "end": 817, "ctxt": 0 }, "callee": { "type": "MemberExpression", "span": { "start": 796, "end": 815, "ctxt": 0 }, "object": { "type": "Identifier", "span": { "start": 796, "end": 802, "ctxt": 0 }, "value": "render", "optional": false }, "property": { "type": "Identifier", "span": { "start": 803, "end": 815, "ctxt": 0 }, "value": "addRectangle", "optional": false } }, "arguments": [], "typeArguments": null } }, { "type": "ExpressionStatement", "span": { "start": 819, "end": 858, "ctxt": 0 }, "expression": { "type": "CallExpression", "span": { "start": 819, "end": 857, "ctxt": 0 }, "callee": { "type": "MemberExpression", "span": { "start": 819, "end": 830, "ctxt": 0 }, "object": { "type": "Identifier", "span": { "start": 819, "end": 826, "ctxt": 0 }, "value": "console", "optional": false }, "property": { "type": "Identifier", "span": { "start": 827, "end": 830, "ctxt": 0 }, "value": "log", "optional": false } }, "arguments": [ { "spread": null, "expression": { "type": "StringLiteral", "span": { "start": 831, "end": 840, "ctxt": 0 }, "value": "Objects", "hasEscape": false, "kind": { "type": "normal", "containsQuote": true } } }, { "spread": null, "expression": { "type": "MemberExpression", "span": { "start": 842, "end": 856, "ctxt": 0 }, "object": { "type": "Identifier", "span": { "start": 842, "end": 848, "ctxt": 0 }, "value": "render", "optional": false }, "property": { "type": "Identifier", "span": { "start": 849, "end": 856, "ctxt": 0 }, "value": "objects", "optional": false } } } ], "typeArguments": null } } ], "interpreter": null }