(href: string, baseUrl: string)
| 94 | * Helper function used to validate URLs used when extracting URLs from a page |
| 95 | */ |
| 96 | export function tryAbsoluteURL(href: string, baseUrl: string): string | undefined { |
| 97 | try { |
| 98 | return new URL(href, baseUrl).href; |
| 99 | } catch { |
| 100 | return undefined; |
| 101 | } |
| 102 | } |
no outgoing calls
no test coverage detected
searching dependent graphs…