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

Function pageOf

ui/src/lib/filecode-model.ts:154–156  ·  view source on GitHub ↗
(line: number)

Source from the content-addressed store, hash-verified

152}
153
154export function pageOf(line: number): number {
155 return Math.floor((line - 1) / PAGE_LINES);
156}
157
158export function pageFor(index: number, totalLines: number): SourcePage {
159 const from = index * PAGE_LINES + 1;

Callers 2

pagesForRangeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected