Skip to content

Commit

Permalink
fix(useVModel)!: rename type VModelOptions to UseVModelOptions (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
okxiaoliang4 committed Jul 13, 2022
1 parent 35f33e2 commit 7155053
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions packages/core/useVModel/index.ts
Expand Up @@ -2,7 +2,7 @@ import { isDef } from '@vueuse/shared'
import type { UnwrapRef } from 'vue-demi'
import { computed, getCurrentInstance, isVue2, ref, watch } from 'vue-demi'

export interface VModelOptions<T> {
export interface UseVModelOptions<T> {
/**
* When passive is set to `true`, it will use `watch` to sync with props and ref.
* Instead of relying on the `v-model` or `.sync` to work.
Expand Down Expand Up @@ -43,7 +43,7 @@ export function useVModel<P extends object, K extends keyof P, Name extends stri
props: P,
key?: K,
emit?: (name: Name, ...args: any[]) => void,
options: VModelOptions<P[K]> = {},
options: UseVModelOptions<P[K]> = {},
) {
const {
passive = false,
Expand Down
4 changes: 2 additions & 2 deletions packages/core/useVModels/index.ts
@@ -1,5 +1,5 @@
import type { ToRefs } from 'vue-demi'
import type { VModelOptions } from '../useVModel'
import type { UseVModelOptions } from '../useVModel'
import { useVModel } from '../useVModel'

/**
Expand All @@ -12,7 +12,7 @@ import { useVModel } from '../useVModel'
export function useVModels<P extends object, Name extends string>(
props: P,
emit?: (name: Name, ...args: any[]) => void,
options: VModelOptions<any> = {},
options: UseVModelOptions<any> = {},
): ToRefs<P> {
const ret: any = {}

Expand Down

0 comments on commit 7155053

Please sign in to comment.