MCPcopy Create free account
hub / github.com/DeusData/codebase-memory-mcp / entryRows

Function entryRows

graph-ui/src/entry/entry-model.ts:137–154  ·  view source on GitHub ↗
(
    overview: Pick<ArchitectureOverviewDto, 'entryPoints' | 'routes'> | undefined,
    limit: number = MAX_ENTRY_ROWS,
)

Source from the content-addressed store, hash-verified

135 * not reshuffle between two openings of the same dialog.
136 */
137export function entryRows(
138 overview: Pick<ArchitectureOverviewDto, 'entryPoints' | 'routes'> | undefined,
139 limit: number = MAX_ENTRY_ROWS,
140): { rows: EntryRow[]; total: number } {
141 const all = [
142 ...(overview?.entryPoints ?? []).map(rowOfHit),
143 ...(overview?.routes ?? []).map(rowOfRoute),
144 ];
145 const seen = new Set<string>();
146 const unique = all.filter((row) => {
147 if (seen.has(row.key)) {
148 return false;
149 }
150 seen.add(row.key);
151 return true;
152 });
153 return { rows: unique.slice(0, Math.max(0, limit)), total: unique.length };
154}

Callers 2

ProjectWindowViewFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected