Fable findings in data
This commit is contained in:
parent
b98bc6d611
commit
6a33b03fdf
20 changed files with 1502 additions and 274 deletions
|
|
@ -171,8 +171,7 @@ function pageToPath(page: Page, inviteCode?: string): string {
|
|||
|
||||
function pathToPage(rawPathname: string): RouteMatch | null {
|
||||
// Proxies 307-redirect /learn -> /learn/; treat trailing slashes as equivalent.
|
||||
const pathname =
|
||||
rawPathname.length > 1 ? rawPathname.replace(/\/+$/, '') || '/' : rawPathname;
|
||||
const pathname = rawPathname.length > 1 ? rawPathname.replace(/\/+$/, '') || '/' : rawPathname;
|
||||
if (pathname === '/dashboard') return { page: 'dashboard' };
|
||||
if (pathname === '/saved') return { page: 'saved' };
|
||||
if (pathname === '/invites') return { page: 'account', hash: 'invites' };
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue