| 1 | export as namespace URLToolkit; |
| 2 | |
| 3 | export type URLParts = { |
| 4 | scheme: string; |
| 5 | netLoc: string; |
| 6 | path: string; |
| 7 | params: string; |
| 8 | query: string; |
| 9 | fragment: string; |
| 10 | }; |
| 11 | |
| 12 | export function buildAbsoluteURL( |
| 13 | baseURL: string, |
| 14 | relativeURL: string, |
| 15 | opts?: { alwaysNormalize?: boolean } |
| 16 | ): string; |
| 17 | |
| 18 | export function parseURL(url: string): URLParts | null; |
| 19 | |
| 20 | export function normalizePath(path: string): string; |
| 21 | |
| 22 | export function buildURLFromParts(parts: URLParts): string; |