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

Function stripProtocol

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

Source from the content-addressed store, hash-verified

1const isProd = () => process.env.NODE_ENV === 'production';
2
3export function stripProtocol(url: string): string {
4 return url.replace(/^https?:\/\//, '');
5}
6
7export function normalizeUrl(url: string): string {
8 return url.replace(/\.\.(\w+)$/, '.$1');

Callers 4

url.test.tsFile · 0.90
updateMethod · 0.90
validateDomainFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected