MCPcopy Index your code
hub / github.com/callumalpass/tasknotes / normalizeSubpathLabel

Function normalizeSubpathLabel

src/editor/taskLinkDisplayText.ts:25–29  ·  view source on GitHub ↗
(value: string | undefined)

Source from the content-addressed store, hash-verified

23}
24
25function normalizeSubpathLabel(value: string | undefined): string {
26 if (!value) return "";
27 const decoded = safeDecodeURIComponent(value).trim();
28 return decoded.replace(/^[#^]+/, "").trim();
29}
30
31function basename(value: string): string {
32 const normalized = normalizePathLikeLabel(value);

Callers 3

extractTaskLinkSubpathFunction · 0.85

Calls 1

safeDecodeURIComponentFunction · 0.70

Tested by

no test coverage detected