Skip to content

Commit 007ebcc

Browse files
committed
Make the types easier to use, splitting into withPagination and withPaginationNoCursor
1 parent f9f38bd commit 007ebcc

File tree

4 files changed

+217
-140
lines changed

4 files changed

+217
-140
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,4 +181,4 @@ console.log(edgesWithRawCursor[0].rawCursor);
181181

182182
This can then be provided to `before`/`after` by wrapping the object with `rawCursor(object)`.
183183

184-
You can also omit the `cursorSecret` and `cursor` will not be generated.
184+
You can also use `withPaginationNoCursor`, which takes the same input as `withPagination` excluding the `cursorSecret`, and `cursor` will not be generated.

src/cursor.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ export async function resolveCursor({
120120
if (typeof cursor === 'string') {
121121
if (cursorSecret === null) {
122122
throw new ErrUnexpected(
123-
'String cursor not supported when no `cursorSecret` is provided',
123+
'String cursor not supported with `withPaginationNoCursor`',
124124
);
125125
}
126126
const res = await decryptCursor({

0 commit comments

Comments
 (0)