Skip to content

Commit

Permalink
fix(useWindowSize)!: rename type WindowSizeOptions to `UseWindowSiz…
Browse files Browse the repository at this point in the history
…eOptions` (#1897)
  • Loading branch information
okxiaoliang4 committed Jul 13, 2022
1 parent b461f3e commit adf3a4d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions packages/core/useWindowSize/component.ts
@@ -1,8 +1,8 @@
import { defineComponent, reactive } from 'vue-demi'
import type { WindowSizeOptions } from '@vueuse/core'
import type { UseWindowSizeOptions } from '@vueuse/core'
import { useWindowSize } from '@vueuse/core'

export const UseWindowSize = defineComponent<WindowSizeOptions>({
export const UseWindowSize = defineComponent<UseWindowSizeOptions>({
name: 'UseWindowSize',
props: ['initialWidth', 'initialHeight'] as unknown as undefined,
setup(props, { slots }) {
Expand Down
4 changes: 2 additions & 2 deletions packages/core/useWindowSize/index.ts
Expand Up @@ -4,7 +4,7 @@ import { useEventListener } from '../useEventListener'
import type { ConfigurableWindow } from '../_configurable'
import { defaultWindow } from '../_configurable'

export interface WindowSizeOptions extends ConfigurableWindow {
export interface UseWindowSizeOptions extends ConfigurableWindow {
initialWidth?: number
initialHeight?: number
/**
Expand All @@ -21,7 +21,7 @@ export interface WindowSizeOptions extends ConfigurableWindow {
* @see https://vueuse.org/useWindowSize
* @param options
*/
export function useWindowSize(options: WindowSizeOptions = {}) {
export function useWindowSize(options: UseWindowSizeOptions = {}) {
const {
window = defaultWindow,
initialWidth = Infinity,
Expand Down

0 comments on commit adf3a4d

Please sign in to comment.