| Category | Sensors |
|---|---|
| Export Size | 576 B |
| Last Changed | last year |
Reactive state to show whether the mouse leaves the page.
import { usePageLeave } from '@vueuse/core'
const isLeft = usePageLeave()
This function also provides a renderless component version via the
@vueuse/componentspackage. Learn more about the usage.
<UsePageLeave v-slot="{ isLeft }">
Has Left Page: {{ isLeft }}
</UsePageLeave>
/** * Reactive state to show whether mouse leaves the page. * * @see https://vueuse.org/usePageLeave * @param options */ export declare function usePageLeave(options?: ConfigurableWindow): Ref<boolean>
© 2019-present Anthony Fu
Licensed under the MIT License.
https://vueuse.org/core/usePageLeave/