()
| 24 | } |
| 25 | |
| 26 | export function getSnapshot() { |
| 27 | if (cachedSnapshot.promise !== navigationPromise || cachedSnapshot.pathname !== targetPathname) { |
| 28 | cachedSnapshot = {promise: navigationPromise, pathname: targetPathname}; |
| 29 | } |
| 30 | return cachedSnapshot; |
| 31 | } |
| 32 | |
| 33 | export function setNavigationPromise(promise: Promise<void> | null, pathname?: string) { |
| 34 | targetPathname = pathname || null; |
no outgoing calls
no test coverage detected