Debian Codegraph @

packages/babel-parser/test/fixtures/jsx/basic/8/output.json

raw
1 {
2 "type": "File",
3 "start":0,"end":27,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":27,"index":27}},
4 "program": {
5 "type": "Program",
6 "start":0,"end":27,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":27,"index":27}},
7 "sourceType": "script",
8 "interpreter": null,
9 "body": [
10 {
11 "type": "ExpressionStatement",
12 "start":0,"end":27,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":27,"index":27}},
13 "expression": {
14 "type": "JSXElement",
15 "start":0,"end":27,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":27,"index":27}},
16 "openingElement": {
17 "type": "JSXOpeningElement",
18 "start":0,"end":27,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":27,"index":27}},
19 "name": {
20 "type": "JSXIdentifier",
21 "start":1,"end":2,"loc":{"start":{"line":1,"column":1,"index":1},"end":{"line":1,"column":2,"index":2}},
22 "name": "a"
23 },
24 "attributes": [
25 {
26 "type": "JSXAttribute",
27 "start":3,"end":24,"loc":{"start":{"line":1,"column":3,"index":3},"end":{"line":1,"column":24,"index":24}},
28 "name": {
29 "type": "JSXIdentifier",
30 "start":3,"end":4,"loc":{"start":{"line":1,"column":3,"index":3},"end":{"line":1,"column":4,"index":4}},
31 "name": "b"
32 },
33 "value": {
34 "type": "JSXExpressionContainer",
35 "start":5,"end":24,"loc":{"start":{"line":1,"column":5,"index":5},"end":{"line":1,"column":24,"index":24}},
36 "expression": {
37 "type": "ConditionalExpression",
38 "start":6,"end":23,"loc":{"start":{"line":1,"column":6,"index":6},"end":{"line":1,"column":23,"index":23}},
39 "test": {
40 "type": "Identifier",
41 "start":6,"end":7,"loc":{"start":{"line":1,"column":6,"index":6},"end":{"line":1,"column":7,"index":7},"identifierName":"x"},
42 "name": "x"
43 },
44 "consequent": {
45 "type": "JSXElement",
46 "start":10,"end":15,"loc":{"start":{"line":1,"column":10,"index":10},"end":{"line":1,"column":15,"index":15}},
47 "openingElement": {
48 "type": "JSXOpeningElement",
49 "start":10,"end":15,"loc":{"start":{"line":1,"column":10,"index":10},"end":{"line":1,"column":15,"index":15}},
50 "name": {
51 "type": "JSXIdentifier",
52 "start":11,"end":12,"loc":{"start":{"line":1,"column":11,"index":11},"end":{"line":1,"column":12,"index":12}},
53 "name": "c"
54 },
55 "attributes": [],
56 "selfClosing": true
57 },
58 "closingElement": null,
59 "children": []
60 },
61 "alternate": {
62 "type": "JSXElement",
63 "start":18,"end":23,"loc":{"start":{"line":1,"column":18,"index":18},"end":{"line":1,"column":23,"index":23}},
64 "openingElement": {
65 "type": "JSXOpeningElement",
66 "start":18,"end":23,"loc":{"start":{"line":1,"column":18,"index":18},"end":{"line":1,"column":23,"index":23}},
67 "name": {
68 "type": "JSXIdentifier",
69 "start":19,"end":20,"loc":{"start":{"line":1,"column":19,"index":19},"end":{"line":1,"column":20,"index":20}},
70 "name": "d"
71 },
72 "attributes": [],
73 "selfClosing": true
74 },
75 "closingElement": null,
76 "children": []
77 }
78 }
79 }
80 }
81 ],
82 "selfClosing": true
83 },
84 "closingElement": null,
85 "children": []
86 }
87 }
88 ],
89 "directives": []
90 }
91 }