MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / elementPage

Function elementPage

src/resolution/frameworks/react.ts:1088–1088  ·  view source on GitHub ↗
(value: string | undefined)

Source from the content-addressed store, hash-verified

1086 const elementTag = (value: string | undefined): string | undefined => componentName(value, true);
1087 // The page an `element` shows: `element={<Outlet />}` renders the route inside it and nothing of its own.
1088 const elementPage = (value: string | undefined): string | undefined => elementTag(value)?.replace(/^Outlet$/, '') || undefined;
1089 // The few characters before `at`, trailing whitespace skipped: enough for the
1090 // end-anchored checks below without copying the whole prefix per `/` or `<`.
1091 const tokenBefore = (at: number): string => {

Callers 1

jsxFunction · 0.85

Calls 1

elementTagFunction · 0.85

Tested by

no test coverage detected