Debian Codegraph @

packages/babel-parser/test/fixtures/flow/declare-export/export-class/output.json

raw
1 {
2 "type": "File",
3 "start":0,"end":77,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":77,"index":77}},
4 "program": {
5 "type": "Program",
6 "start":0,"end":77,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":77,"index":77}},
7 "sourceType": "module",
8 "interpreter": null,
9 "body": [
10 {
11 "type": "DeclareModule",
12 "start":0,"end":77,"loc":{"start":{"line":1,"column":0,"index":0},"end":{"line":1,"column":77,"index":77}},
13 "id": {
14 "type": "StringLiteral",
15 "start":15,"end":20,"loc":{"start":{"line":1,"column":15,"index":15},"end":{"line":1,"column":20,"index":20}},
16 "extra": {
17 "rawValue": "foo",
18 "raw": "\"foo\""
19 },
20 "value": "foo"
21 },
22 "body": {
23 "type": "BlockStatement",
24 "start":21,"end":77,"loc":{"start":{"line":1,"column":21,"index":21},"end":{"line":1,"column":77,"index":77}},
25 "body": [
26 {
27 "type": "DeclareExportDeclaration",
28 "start":23,"end":75,"loc":{"start":{"line":1,"column":23,"index":23},"end":{"line":1,"column":75,"index":75}},
29 "declaration": {
30 "type": "DeclareClass",
31 "start":38,"end":75,"loc":{"start":{"line":1,"column":38,"index":38},"end":{"line":1,"column":75,"index":75}},
32 "id": {
33 "type": "Identifier",
34 "start":44,"end":47,"loc":{"start":{"line":1,"column":44,"index":44},"end":{"line":1,"column":47,"index":47},"identifierName":"Foo"},
35 "name": "Foo"
36 },
37 "typeParameters": null,
38 "extends": [],
39 "implements": [],
40 "mixins": [],
41 "body": {
42 "type": "ObjectTypeAnnotation",
43 "start":48,"end":75,"loc":{"start":{"line":1,"column":48,"index":48},"end":{"line":1,"column":75,"index":75}},
44 "callProperties": [],
45 "properties": [
46 {
47 "type": "ObjectTypeProperty",
48 "start":50,"end":72,"loc":{"start":{"line":1,"column":50,"index":50},"end":{"line":1,"column":72,"index":72}},
49 "key": {
50 "type": "Identifier",
51 "start":50,"end":54,"loc":{"start":{"line":1,"column":50,"index":50},"end":{"line":1,"column":54,"index":54},"identifierName":"meth"},
52 "name": "meth"
53 },
54 "static": false,
55 "proto": false,
56 "kind": "init",
57 "method": true,
58 "value": {
59 "type": "FunctionTypeAnnotation",
60 "start":50,"end":72,"loc":{"start":{"line":1,"column":50,"index":50},"end":{"line":1,"column":72,"index":72}},
61 "params": [
62 {
63 "type": "FunctionTypeParam",
64 "start":55,"end":65,"loc":{"start":{"line":1,"column":55,"index":55},"end":{"line":1,"column":65,"index":65}},
65 "name": {
66 "type": "Identifier",
67 "start":55,"end":57,"loc":{"start":{"line":1,"column":55,"index":55},"end":{"line":1,"column":57,"index":57},"identifierName":"p1"},
68 "name": "p1"
69 },
70 "optional": false,
71 "typeAnnotation": {
72 "type": "NumberTypeAnnotation",
73 "start":59,"end":65,"loc":{"start":{"line":1,"column":59,"index":59},"end":{"line":1,"column":65,"index":65}}
74 }
75 }
76 ],
77 "rest": null,
78 "typeParameters": null,
79 "this": null,
80 "returnType": {
81 "type": "VoidTypeAnnotation",
82 "start":68,"end":72,"loc":{"start":{"line":1,"column":68,"index":68},"end":{"line":1,"column":72,"index":72}}
83 }
84 },
85 "optional": false
86 }
87 ],
88 "indexers": [],
89 "internalSlots": [],
90 "exact": false
91 }
92 },
93 "default": false
94 }
95 ]
96 },
97 "kind": "ES"
98 }
99 ],
100 "directives": []
101 }
102 }