MCPcopy Index your code
hub / github.com/TanStack/table / fetchData

Function fetchData

examples/react/pagination-controlled/src/fetchData.ts:52–67  ·  view source on GitHub ↗
(options: {
  pageIndex: number
  pageSize: number
})

Source from the content-addressed store, hash-verified

50const data = makeData(10000)
51
52export async function fetchData(options: {
53 pageIndex: number
54 pageSize: number
55}) {
56 // Simulate some network latency
57 await new Promise(r => setTimeout(r, 500))
58
59 return {
60 rows: data.slice(
61 options.pageIndex * options.pageSize,
62 (options.pageIndex + 1) * options.pageSize
63 ),
64 pageCount: Math.ceil(data.length / options.pageSize),
65 rowCount: data.length,
66 }
67}

Callers 1

AppFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…