-
Notifications
You must be signed in to change notification settings - Fork 155
/
Copy pathresolvers.ts
33 lines (31 loc) · 927 Bytes
/
resolvers.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
import { type ResolverConfig } from '@urql/exchange-graphcache';
import { relayPagination } from '@urql/exchange-graphcache/extras';
import { merge } from 'lodash-es';
import scalarResolvers from './scalars/resolvers';
export default merge(scalarResolvers, {
Query: {
heldForModeration: relayPagination(),
},
Profile: {
library: relayPagination(),
},
Library: {
all: relayPagination(),
completed: relayPagination(),
current: relayPagination(),
dropped: relayPagination(),
onHold: relayPagination(),
planned: relayPagination(),
},
Anime: {
episodes: relayPagination(),
characters: relayPagination(),
categories: relayPagination(),
mappings: relayPagination(),
productions: relayPagination(),
quotes: relayPagination(),
reactions: relayPagination(),
staff: relayPagination(),
streamingLinks: relayPagination(),
},
}) satisfies ResolverConfig;