From Dev.to
Your cursor pagination is probably losing rows (JS Dates vs Postgres microseconds)
Keyset (cursor) pagination is the standard fix for slow OFFSET queries. You sort by created_at plus id, encode the last row into a cursor, and ask for "rows older than this" on the next page. There's...
