File tree Expand file tree Collapse file tree 1 file changed +8
-4
lines changed
packages/runtime-core/src Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -98,8 +98,8 @@ export type DefineComponent<
9898 directives ?: Directives & GlobalDirectives
9999 expose ?: Exposed [ ]
100100 provide ?: Provide
101- setup ?: ( ) => RawBindings
102- data ?: ( ) => D
101+ setup ?: ( props : any , ctx : SetupContext ) => RawBindings
102+ data ?: ( vm : any ) => D
103103 __typeProps ?: OptionsOrPropsOrPropOptions extends ComponentPropsOptions
104104 ? unknown
105105 : OptionsOrPropsOrPropOptions
@@ -124,8 +124,8 @@ type InferComponentOptions<
124124 methods ?: infer Methods
125125 mixins ?: ( infer Mixin ) [ ]
126126 extends ?: infer Extends
127- setup ?( ) : infer SetupBindings
128- data ?( ) : infer Data
127+ setup ?( props : any , ctx : any ) : infer SetupBindings
128+ data ?( vm : any ) : infer Data
129129 __typeProps ?: infer TypeProps
130130 __typeEmits ?: infer TypeEmits
131131 __typeRefs ?: infer TypeRefs
@@ -141,6 +141,10 @@ type InferComponentOptions<
141141 * because the `__differentiator` will be different
142142 */
143143 __differentiator ?: keyof Data | keyof Computed | keyof Methods
144+
145+ // allow any custom options
146+ [ key : string ] : any
147+
144148 new ( ...args : any [ ] ) : ComponentPublicInstance <
145149 Readonly <
146150 ExtractPropTypes <
You can’t perform that action at this time.
0 commit comments