MCPcopy Create free account
hub / github.com/Linen-dev/linen.dev / normalizeUrl

Function normalizeUrl

packages/utilities/src/url.ts:7–9  ·  view source on GitHub ↗
(url: string)

Source from the content-addressed store, hash-verified

5}
6
7export function normalizeUrl(url: string): string {
8 return url.replace(/\.\.(\w+)$/, '.$1');
9}
10
11export const appendProtocol = (host: string) =>
12 `${isProd() ? 'https' : 'http'}://${host}`;

Callers 1

url.test.tsFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected