MCPcopy
hub / github.com/directus/directus / getRootPath

Function getRootPath

app/src/utils/get-root-path.ts:4–6  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2 * Get the API root location from the current window path
3 */
4export function getRootPath(): string {
5 return extractRoot(window.location.pathname);
6}
7
8/**
9 * Get the full API root URL from the current page href

Callers 8

loadExtensionsFunction · 0.90
router.tsFile · 0.90
api.tsFile · 0.90
uploadFileFunction · 0.90
parseUrlFunction · 0.90
navigateAfterLoginFunction · 0.90
translateLanguageFunction · 0.90

Calls 1

extractRootFunction · 0.85

Tested by

no test coverage detected