Debian Codegraph @

packages/babel-parser/test/fixtures/experimental/decorators-legacy/object-method-parameter/output.json

raw
1 {
2 "type": "File",
3 "start":0,"end":63,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":3,"column":2,"index":63}},
4 "program": {
5 "type": "Program",
6 "start":0,"end":63,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":3,"column":2,"index":63}},
7 "sourceType": "script",
8 "interpreter": null,
9 "body": [
10 {
11 "type": "VariableDeclaration",
12 "start":0,"end":63,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":3,"column":2,"index":63}},
13 "declarations": [
14 {
15 "type": "VariableDeclarator",
16 "start":4,"end":62,"loc":{"start":{"line":1,"column":4,"index":4},"end":{"line":3,"column":1,"index":62}},
17 "id": {
18 "type": "Identifier",
19 "start":4,"end":7,"loc":{"start":{"line":1,"column":4,"index":4},"end":{"line":1,"column":7,"index":7},"identifierName":"obj"},
20 "name": "obj"
21 },
22 "init": {
23 "type": "ObjectExpression",
24 "start":10,"end":62,"loc":{"start":{"line":1,"column":10,"index":10},"end":{"line":3,"column":1,"index":62}},
25 "properties": [
26 {
27 "type": "ObjectMethod",
28 "start":14,"end":60,"loc":{"start":{"line":2,"column":2,"index":14},"end":{"line":2,"column":48,"index":60}},
29 "method": true,
30 "key": {
31 "type": "Identifier",
32 "start":14,"end":20,"loc":{"start":{"line":2,"column":2,"index":14},"end":{"line":2,"column":8,"index":20},"identifierName":"method"},
33 "name": "method"
34 },
35 "computed": false,
36 "kind": "method",
37 "id": null,
38 "generator": false,
39 "async": false,
40 "params": [
41 {
42 "type": "Identifier",
43 "start":28,"end":29,"loc":{"start":{"line":2,"column":16,"index":28},"end":{"line":2,"column":17,"index":29},"identifierName":"x"},
44 "name": "x",
45 "decorators": [
46 {
47 "type": "Decorator",
48 "start":21,"end":27,"loc":{"start":{"line":2,"column":9,"index":21},"end":{"line":2,"column":15,"index":27}},
49 "expression": {
50 "type": "CallExpression",
51 "start":22,"end":27,"loc":{"start":{"line":2,"column":10,"index":22},"end":{"line":2,"column":15,"index":27}},
52 "callee": {
53 "type": "Identifier",
54 "start":22,"end":25,"loc":{"start":{"line":2,"column":10,"index":22},"end":{"line":2,"column":13,"index":25},"identifierName":"foo"},
55 "name": "foo"
56 },
57 "arguments": []
58 }
59 }
60 ]
61 },
62 {
63 "type": "Identifier",
64 "start":55,"end":56,"loc":{"start":{"line":2,"column":43,"index":55},"end":{"line":2,"column":44,"index":56},"identifierName":"y"},
65 "name": "y",
66 "decorators": [
67 {
68 "type": "Decorator",
69 "start":31,"end":47,"loc":{"start":{"line":2,"column":19,"index":31},"end":{"line":2,"column":35,"index":47}},
70 "expression": {
71 "type": "CallExpression",
72 "start":32,"end":47,"loc":{"start":{"line":2,"column":20,"index":32},"end":{"line":2,"column":35,"index":47}},
73 "callee": {
74 "type": "Identifier",
75 "start":32,"end":35,"loc":{"start":{"line":2,"column":20,"index":32},"end":{"line":2,"column":23,"index":35},"identifierName":"bar"},
76 "name": "bar"
77 },
78 "arguments": [
79 {
80 "type": "ObjectExpression",
81 "start":36,"end":46,"loc":{"start":{"line":2,"column":24,"index":36},"end":{"line":2,"column":34,"index":46}},
82 "properties": [
83 {
84 "type": "ObjectProperty",
85 "start":38,"end":44,"loc":{"start":{"line":2,"column":26,"index":38},"end":{"line":2,"column":32,"index":44}},
86 "method": false,
87 "key": {
88 "type": "Identifier",
89 "start":38,"end":39,"loc":{"start":{"line":2,"column":26,"index":38},"end":{"line":2,"column":27,"index":39},"identifierName":"a"},
90 "name": "a"
91 },
92 "computed": false,
93 "shorthand": false,
94 "value": {
95 "type": "NumericLiteral",
96 "start":41,"end":44,"loc":{"start":{"line":2,"column":29,"index":41},"end":{"line":2,"column":32,"index":44}},
97 "extra": {
98 "rawValue": 123,
99 "raw": "123"
100 },
101 "value": 123
102 }
103 }
104 ]
105 }
106 ]
107 }
108 },
109 {
110 "type": "Decorator",
111 "start":48,"end":54,"loc":{"start":{"line":2,"column":36,"index":48},"end":{"line":2,"column":42,"index":54}},
112 "expression": {
113 "type": "CallExpression",
114 "start":49,"end":54,"loc":{"start":{"line":2,"column":37,"index":49},"end":{"line":2,"column":42,"index":54}},
115 "callee": {
116 "type": "Identifier",
117 "start":49,"end":52,"loc":{"start":{"line":2,"column":37,"index":49},"end":{"line":2,"column":40,"index":52},"identifierName":"baz"},
118 "name": "baz"
119 },
120 "arguments": []
121 }
122 }
123 ]
124 }
125 ],
126 "body": {
127 "type": "BlockStatement",
128 "start":58,"end":60,"loc":{"start":{"line":2,"column":46,"index":58},"end":{"line":2,"column":48,"index":60}},
129 "body": [],
130 "directives": []
131 }
132 }
133 ]
134 }
135 }
136 ],
137 "kind": "var"
138 }
139 ],
140 "directives": []
141 }
142 }