# Navigation

TypeScript source: `hooks/navigation.ts`

## Functions

### useNavigation

Source: `hooks/navigation.ts:8`

```ts
(parseUrl?: (pathname: string) => { basePath: string; page: string }) => { basePath: string; makePath: (page: string, options: { noSearch?: boolean; rootPage?: string }) => string; page: string }
```

Resolves the current viewer page and builds navigation paths that preserve search params.

#### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| `parseUrl?` | `(pathname: string) => { basePath: string; page: string }` | Optional custom parser for host applications with
different routing. |
