File tree Expand file tree Collapse file tree 2 files changed +267
-0
lines changed Expand file tree Collapse file tree 2 files changed +267
-0
lines changed Original file line number Diff line number Diff line change
1
+ [
2
+ {
3
+ "marker" : {
4
+ "fileName" : "/tests/cases/fourslash/jsDocTypedef1.js" ,
5
+ "position" : 189
6
+ } ,
7
+ "quickInfo" : {
8
+ "kind" : "parameter" ,
9
+ "kindModifiers" : "" ,
10
+ "textSpan" : {
11
+ "start" : 189 ,
12
+ "length" : 4
13
+ } ,
14
+ "displayParts" : [
15
+ {
16
+ "text" : "(" ,
17
+ "kind" : "punctuation"
18
+ } ,
19
+ {
20
+ "text" : "parameter" ,
21
+ "kind" : "text"
22
+ } ,
23
+ {
24
+ "text" : ")" ,
25
+ "kind" : "punctuation"
26
+ } ,
27
+ {
28
+ "text" : " " ,
29
+ "kind" : "space"
30
+ } ,
31
+ {
32
+ "text" : "opts" ,
33
+ "kind" : "parameterName"
34
+ } ,
35
+ {
36
+ "text" : ":" ,
37
+ "kind" : "punctuation"
38
+ } ,
39
+ {
40
+ "text" : " " ,
41
+ "kind" : "space"
42
+ } ,
43
+ {
44
+ "text" : "{" ,
45
+ "kind" : "punctuation"
46
+ } ,
47
+ {
48
+ "text" : "\n" ,
49
+ "kind" : "lineBreak"
50
+ } ,
51
+ {
52
+ "text" : " " ,
53
+ "kind" : "space"
54
+ } ,
55
+ {
56
+ "text" : "x" ,
57
+ "kind" : "propertyName"
58
+ } ,
59
+ {
60
+ "text" : ":" ,
61
+ "kind" : "punctuation"
62
+ } ,
63
+ {
64
+ "text" : " " ,
65
+ "kind" : "space"
66
+ } ,
67
+ {
68
+ "text" : "string" ,
69
+ "kind" : "keyword"
70
+ } ,
71
+ {
72
+ "text" : ";" ,
73
+ "kind" : "punctuation"
74
+ } ,
75
+ {
76
+ "text" : "\n" ,
77
+ "kind" : "lineBreak"
78
+ } ,
79
+ {
80
+ "text" : " " ,
81
+ "kind" : "space"
82
+ } ,
83
+ {
84
+ "text" : "y" ,
85
+ "kind" : "propertyName"
86
+ } ,
87
+ {
88
+ "text" : "?" ,
89
+ "kind" : "punctuation"
90
+ } ,
91
+ {
92
+ "text" : ":" ,
93
+ "kind" : "punctuation"
94
+ } ,
95
+ {
96
+ "text" : " " ,
97
+ "kind" : "space"
98
+ } ,
99
+ {
100
+ "text" : "string" ,
101
+ "kind" : "keyword"
102
+ } ,
103
+ {
104
+ "text" : ";" ,
105
+ "kind" : "punctuation"
106
+ } ,
107
+ {
108
+ "text" : "\n" ,
109
+ "kind" : "lineBreak"
110
+ } ,
111
+ {
112
+ "text" : " " ,
113
+ "kind" : "space"
114
+ } ,
115
+ {
116
+ "text" : "z" ,
117
+ "kind" : "propertyName"
118
+ } ,
119
+ {
120
+ "text" : "?" ,
121
+ "kind" : "punctuation"
122
+ } ,
123
+ {
124
+ "text" : ":" ,
125
+ "kind" : "punctuation"
126
+ } ,
127
+ {
128
+ "text" : " " ,
129
+ "kind" : "space"
130
+ } ,
131
+ {
132
+ "text" : "string" ,
133
+ "kind" : "keyword"
134
+ } ,
135
+ {
136
+ "text" : ";" ,
137
+ "kind" : "punctuation"
138
+ } ,
139
+ {
140
+ "text" : "\n" ,
141
+ "kind" : "lineBreak"
142
+ } ,
143
+ {
144
+ "text" : " " ,
145
+ "kind" : "space"
146
+ } ,
147
+ {
148
+ "text" : "w" ,
149
+ "kind" : "propertyName"
150
+ } ,
151
+ {
152
+ "text" : "?" ,
153
+ "kind" : "punctuation"
154
+ } ,
155
+ {
156
+ "text" : ":" ,
157
+ "kind" : "punctuation"
158
+ } ,
159
+ {
160
+ "text" : " " ,
161
+ "kind" : "space"
162
+ } ,
163
+ {
164
+ "text" : "string" ,
165
+ "kind" : "keyword"
166
+ } ,
167
+ {
168
+ "text" : ";" ,
169
+ "kind" : "punctuation"
170
+ } ,
171
+ {
172
+ "text" : "\n" ,
173
+ "kind" : "lineBreak"
174
+ } ,
175
+ {
176
+ "text" : "}" ,
177
+ "kind" : "punctuation"
178
+ }
179
+ ] ,
180
+ "documentation" : [ ] ,
181
+ "tags" : [ ]
182
+ }
183
+ } ,
184
+ {
185
+ "marker" : {
186
+ "fileName" : "/tests/cases/fourslash/jsDocTypedef1.js" ,
187
+ "position" : 424
188
+ } ,
189
+ "quickInfo" : {
190
+ "kind" : "parameter" ,
191
+ "kindModifiers" : "" ,
192
+ "textSpan" : {
193
+ "start" : 424 ,
194
+ "length" : 5
195
+ } ,
196
+ "displayParts" : [
197
+ {
198
+ "text" : "(" ,
199
+ "kind" : "punctuation"
200
+ } ,
201
+ {
202
+ "text" : "parameter" ,
203
+ "kind" : "text"
204
+ } ,
205
+ {
206
+ "text" : ")" ,
207
+ "kind" : "punctuation"
208
+ } ,
209
+ {
210
+ "text" : " " ,
211
+ "kind" : "space"
212
+ } ,
213
+ {
214
+ "text" : "opts1" ,
215
+ "kind" : "parameterName"
216
+ } ,
217
+ {
218
+ "text" : ":" ,
219
+ "kind" : "punctuation"
220
+ } ,
221
+ {
222
+ "text" : " " ,
223
+ "kind" : "space"
224
+ } ,
225
+ {
226
+ "text" : "any" ,
227
+ "kind" : "keyword"
228
+ }
229
+ ] ,
230
+ "documentation" : [ ] ,
231
+ "tags" : [ ]
232
+ }
233
+ }
234
+ ]
Original file line number Diff line number Diff line change
1
+ /// <reference path="fourslash.ts" />
2
+ // @allowJs : true
3
+ // @Filename : jsDocTypedef1.js
4
+ //// /**
5
+ //// * @typedef {Object } Opts
6
+ //// * @property {string } x
7
+ //// * @property {string= } y
8
+ //// * @property {string } [z]
9
+ //// * @property {string } [w="hi"]
10
+ //// *
11
+ //// * @param {Opts } opts
12
+ //// */
13
+ //// function foo(/*1*/opts) {
14
+ //// opts.x;
15
+ ///// }
16
+
17
+ //// foo({x: 'abc'});
18
+
19
+ //// /**
20
+ //// * @typedef {object } Opts1
21
+ //// * @property {string } x
22
+ //// * @property {string= } y
23
+ //// * @property {string } [z]
24
+ //// * @property {string } [w="hi"]
25
+ //// *
26
+ //// * @param {Opts1 } opts
27
+ //// */
28
+ //// function foo1(/*2*/opts1) {
29
+ //// opts1.x;
30
+ //// }
31
+ //// foo1({x: 'abc'});
32
+
33
+ verify . baselineQuickInfo ( ) ;
You can’t perform that action at this time.
0 commit comments