summaryrefslogtreecommitdiffstats
path: root/src/services/graphql/articles.query.ts
diff options
context:
space:
mode:
Diffstat (limited to 'src/services/graphql/articles.query.ts')
-rw-r--r--src/services/graphql/articles.query.ts12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/services/graphql/articles.query.ts b/src/services/graphql/articles.query.ts
index e02ca8e..7bd0901 100644
--- a/src/services/graphql/articles.query.ts
+++ b/src/services/graphql/articles.query.ts
@@ -184,3 +184,15 @@ export const totalArticlesQuery = `query PostsTotal($search: String = "") {
}
}
}`;
+
+/**
+ * Query the end cursor based on the queried posts number.
+ */
+export const articlesEndCursor = `query EndCursorAfter($first: Int) {
+ posts(first: $first) {
+ pageInfo {
+ hasNextPage
+ endCursor
+ }
+ }
+}`;