MCPcopy Create free account
hub / github.com/dailydotdev/apps / stripLinkParameters

Function stripLinkParameters

packages/shared/src/lib/links.ts:65–69  ·  view source on GitHub ↗
(link: string)

Source from the content-addressed store, hash-verified

63 url.replace(/(^\w+:|^)\/\//, '');
64
65export const stripLinkParameters = (link: string): string => {
66 const { origin, pathname } = new URL(link);
67
68 return origin + pathname;
69};
70
71export const getDomainFromUrl = (link: string): string => {
72 try {

Callers 1

useNotificationParamsFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected