13 lines
404 B
TypeScript
13 lines
404 B
TypeScript
export const STATISTICS_ROUTE = "/statistics";
|
|
export const STATISTICS_TAB_QUERY_KEY = "tab";
|
|
|
|
export function buildStatisticsTabUrl(tabId: string): string {
|
|
return `${STATISTICS_ROUTE}?${STATISTICS_TAB_QUERY_KEY}=${encodeURIComponent(tabId)}`;
|
|
}
|
|
|
|
export function isStatisticsPathname(
|
|
pathname: string | null,
|
|
): pathname is typeof STATISTICS_ROUTE {
|
|
return pathname === STATISTICS_ROUTE;
|
|
}
|