blob: ab0f0d5781c8bfac81bab3766ca94b99cab0ff74 (
plain)
1
2
3
4
|
/** Get the current page URL: path name + query params. Optionally including hash. */
export const getCurrentUrl = ({ hash }: { hash?: boolean } = {}): string => {
return window.location.pathname + window.location.search + (hash ? window.location.hash : '');
};
|