import { useEffect } from 'react' ; export interface Disposable { ( ) : ( ( ) => void ) | void ; } param { Disposable } onMountCallback export function useMountEffect ( onMountCallback ) { useEffect ( ( ) => onMountCallback ( ) , [ ] ) ; } export default useMountEffect ;