summaryrefslogtreecommitdiff
path: root/apps/web/lib/queries/query-keys.ts
diff options
context:
space:
mode:
Diffstat (limited to 'apps/web/lib/queries/query-keys.ts')
-rw-r--r--apps/web/lib/queries/query-keys.ts43
1 files changed, 43 insertions, 0 deletions
diff --git a/apps/web/lib/queries/query-keys.ts b/apps/web/lib/queries/query-keys.ts
new file mode 100644
index 0000000..69e3407
--- /dev/null
+++ b/apps/web/lib/queries/query-keys.ts
@@ -0,0 +1,43 @@
+export const queryKeys = {
+ timeline: {
+ all: ["timeline"] as const,
+ list: (folderIdentifier?: string | null, feedIdentifier?: string | null, unreadOnly?: boolean) =>
+ ["timeline", { folderIdentifier, feedIdentifier, unreadOnly }] as const,
+ },
+ savedEntries: {
+ all: ["saved-entries"] as const,
+ },
+ subscriptions: {
+ all: ["subscriptions"] as const,
+ },
+ entryDetail: {
+ single: (entryIdentifier: string) =>
+ ["entry-detail", entryIdentifier] as const,
+ },
+ userProfile: {
+ all: ["user-profile"] as const,
+ },
+ mutedKeywords: {
+ all: ["muted-keywords"] as const,
+ },
+ unreadCounts: {
+ all: ["unread-counts"] as const,
+ },
+ entrySearch: {
+ query: (searchQuery: string) => ["entry-search", searchQuery] as const,
+ },
+ entryShare: {
+ single: (entryIdentifier: string) =>
+ ["entry-share", entryIdentifier] as const,
+ },
+ highlights: {
+ forEntry: (entryIdentifier: string) =>
+ ["highlights", entryIdentifier] as const,
+ all: ["highlights"] as const,
+ },
+ customFeeds: {
+ all: ["custom-feeds"] as const,
+ timeline: (customFeedIdentifier: string) =>
+ ["custom-feed-timeline", customFeedIdentifier] as const,
+ },
+}