Skip to content

tryOnBeforeUnmount

Package
Share
Category
Description
safe `onBeforeUnmount`

Safe onBeforeUnmount. Call onBeforeUnmount() if it's inside a component lifecycle, if not, do nothing

Usage

js
import { tryOnBeforeUnmount } from '@hungpvq/shared';

tryOnBeforeUnmount(() => {});