@@ -215,7 +215,7 @@ export function defineSlots<
215215 return null as any
216216}
217217
218- export type ModelRef < T , M extends string | number | symbol = string > = Ref < T > &
218+ export type ModelRef < T , M extends PropertyKey = string > = Ref < T > &
219219 [ ModelRef < T , M > , Record < M , true | undefined > ]
220220
221221export type DefineModelOptions < T = any > = {
@@ -256,24 +256,24 @@ export type DefineModelOptions<T = any> = {
256256 * const count = defineModel<number>('count', { default: 0 })
257257 * ```
258258 */
259- export function defineModel < T , M extends string | number | symbol = string > (
259+ export function defineModel < T , M extends PropertyKey = string > (
260260 options : { required : true } & PropOptions < T > & DefineModelOptions < T > ,
261261) : ModelRef < T , M >
262- export function defineModel < T , M extends string | number | symbol = string > (
262+ export function defineModel < T , M extends PropertyKey = string > (
263263 options : { default : any } & PropOptions < T > & DefineModelOptions < T > ,
264264) : ModelRef < T , M >
265- export function defineModel < T , M extends string | number | symbol = string > (
265+ export function defineModel < T , M extends PropertyKey = string > (
266266 options ?: PropOptions < T > & DefineModelOptions < T > ,
267267) : ModelRef < T | undefined , M >
268- export function defineModel < T , M extends string | number | symbol = string > (
268+ export function defineModel < T , M extends PropertyKey = string > (
269269 name : string ,
270270 options : { required : true } & PropOptions < T > & DefineModelOptions < T > ,
271271) : ModelRef < T , M >
272- export function defineModel < T , M extends string | number | symbol = string > (
272+ export function defineModel < T , M extends PropertyKey = string > (
273273 name : string ,
274274 options : { default : any } & PropOptions < T > & DefineModelOptions < T > ,
275275) : ModelRef < T , M >
276- export function defineModel < T , M extends string | number | symbol = string > (
276+ export function defineModel < T , M extends PropertyKey = string > (
277277 name : string ,
278278 options ?: PropOptions < T > & DefineModelOptions < T > ,
279279) : ModelRef < T | undefined , M >
0 commit comments