MCPcopy Create free account
hub / github.com/arktypeio/arktype / withBase

Function withBase

ark/docs/lib/basePath.ts:16–17  ·  view source on GitHub ↗
(path: string)

Source from the content-addressed store, hash-verified

14
15/** a root-relative path as it's served, e.g. /3/llms.txt for /llms.txt */
16export const withBase = (path: string): string =>
17 path.startsWith("/") ? `${basePath}${path}` : path
18
19/** a served pathname, like location.pathname, as the page url it serves */
20export const withoutBase = (pathname: string): string =>

Callers 11

LinkFunction · 0.90
loadFunction · 0.90
SearchPanelFunction · 0.90
RedirectFunction · 0.90
SiteFooterFunction · 0.90
Playground.tsxFile · 0.90
measureFunction · 0.90
startFunction · 0.90
NotFoundFunction · 0.90
layout.tsxFile · 0.90
DocsPageFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected