-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcache.ts
35 lines (34 loc) · 864 Bytes
/
cache.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
34
35
import { InMemoryCache } from '@apollo/client';
export const cache: InMemoryCache = new InMemoryCache({
typePolicies: {
Note: {
fields: {
isMaximized:{
read(isMaximized = false) {
return isMaximized ;
},
},
isDeleteNoteConfirmationVisible:{
read(isDeleteNoteConfirmationVisible = false) {
return isDeleteNoteConfirmationVisible ;
},
},
isSaving:{
read(isSaving = false) {
return isSaving ;
}
},
isError:{
read(isError = false) {
return isError ;
}
},
isSaved:{
read(isSaved = true) {
return isSaved ;
}
}
}
}
}
})