UNPKG

hd-utils

Version:

A handy utils for modern JS developers

7 lines (6 loc) 290 B
/** * @function onUrlChange * @description -- For Browsers -- * a function that takes callback that will be called whenever the url is changed (ideal for SPA) */ export default function onUrlChange(onPush?: History['pushState'], onPop?: (popstate: PopStateEvent) => void): () => void;