File tree 2 files changed +11
-3
lines changed
packages/react-docgen/src
2 files changed +11
-3
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+ ' react-docgen ' : patch
3
+ ---
4
+
5
+ Add ` displayName ` and ` description ` to Doccumentation type
Original file line number Diff line number Diff line change 1
1
export interface DocumentationObject {
2
- props ?: Record < string , PropDescriptor > ;
3
- context ?: Record < string , PropDescriptor > ;
4
2
childContext ?: Record < string , PropDescriptor > ;
5
3
composes ?: string [ ] ;
4
+ context ?: Record < string , PropDescriptor > ;
5
+ description ?: string ;
6
+ displayName ?: string ;
6
7
methods ?: MethodDescriptor [ ] ;
8
+ props ?: Record < string , PropDescriptor > ;
7
9
}
8
10
9
11
export interface MethodParameter {
10
12
name : string ;
11
- type ?: TypeDescriptor < FunctionSignatureType > | null ;
12
13
optional : boolean ;
14
+ type ?: TypeDescriptor < FunctionSignatureType > | null ;
13
15
}
14
16
15
17
export interface MethodReturn {
@@ -162,6 +164,7 @@ export default class Documentation {
162
164
this . #data. set ( key , value ) ;
163
165
}
164
166
167
+ get < T > ( key : string ) : T | null ;
165
168
get ( key : string ) : unknown {
166
169
return this . #data. get ( key ) ;
167
170
}
You can’t perform that action at this time.
0 commit comments