@@ -12,36 +12,36 @@ Feature/Capability Key:
12
12
- 🔶 Supported and documented, but requires extra user-code to implement
13
13
- 🛑 Not officially supported or documented.
14
14
15
- | | React Query | SWR [ (Website)] ( https://github.com/vercel/swr ) | Apollo Client [ (Website)] ( https://github.com/apollographql/apollo-client ) |
16
- | -------------------------------------------- | -------------------------------------- | ---------------------------------------------- | ------------------------------------------------------------------------- |
17
- | Supported Protocol | HTTP | HTTP | GraphQL |
18
- | Supported Query Signatures | Promise | Promise | GraphQL Query |
19
- | Supported Query Keys | JSON | JSON | GraphQL Query |
20
- | Query Key Change Detection | Deep Compare (Serialization) | Referential Equality (===) | Deep Compare (Serialization) |
21
- | Query Data Memoization Level | Query + Structural Sharing | Query | Query + Entity + Structural Sharing |
22
- | Bundle Size | [ ![ ] [ bp-react-query ]] [ bpl-react-query ] | [ ![ ] [ bp-swr ]] [ bpl-swr ] | [ ![ ] [ bp-apollo ]] [ bpl-apollo ] |
23
- | Queries | ✅ | ✅ | ✅ |
24
- | Caching | ✅ | ✅ | ✅ |
25
- | Devtools | ✅ | 🟡 | ✅ |
26
- | Polling/Intervals | ✅ | ✅ | ✅ |
27
- | Parallel Queries | ✅ | ✅ | ✅ |
28
- | Dependent Queries | ✅ | ✅ | ✅ |
29
- | Paginated Queries | ✅ | 🛑<sup >1</sup > | ✅ |
30
- | Infinite Queries | ✅ | ✅ | ✅ |
31
- | Initial Data | ✅ | ✅ | ✅ |
32
- | Scroll Recovery | ✅ | ✅ | ✅ |
33
- | Cache Manipulation | ✅ | ✅ | ✅ |
34
- | Outdated Query Dismissal | ✅ | ✅ | ✅ |
35
- | Auto Garbage Collection | ✅ | 🛑 | 🛑 |
36
- | Mutation Hooks | ✅ | 🟡 | ✅ |
37
- | Prefetching APIs | ✅ | 🔶 | ✅ |
38
- | Query Cancellation | ✅ | 🛑 | 🛑 |
39
- | Partial Query Matching<sup >2</sup > | ✅ | 🛑 | 🛑 |
40
- | Window Focus Refetching | ✅ | ✅ | 🛑 |
41
- | Network Status Refetching | ✅ | ✅ | ✅ |
42
- | Automatic Refetch after Mutation<sup >3</sup > | 🔶 | 🔶 | ✅ |
43
- | Cache Dehydration/Rehydration | 🛑 | 🛑 | ✅ |
44
- | React Suspense (Experimental) | ✅ | ✅ | 🛑 |
15
+ | | React Query | SWR [ _ (Website)_ ] ( https://github.com/vercel/swr ) | Apollo Client [ _ (Website)_ ] ( https://github.com/apollographql/apollo-client ) |
16
+ | -------------------------------------------- | -------------------------------------- | ------------------------------------------------ | -- ------------------------------------------------------------------------- |
17
+ | Supported Protocol | HTTP | HTTP | GraphQL |
18
+ | Supported Query Signatures | Promise | Promise | GraphQL Query |
19
+ | Supported Query Keys | JSON | JSON | GraphQL Query |
20
+ | Query Key Change Detection | Deep Compare (Serialization) | Referential Equality (===) | Deep Compare (Serialization) |
21
+ | Query Data Memoization Level | Query + Structural Sharing | Query | Query + Entity + Structural Sharing |
22
+ | Bundle Size | [ ![ ] [ bp-react-query ]] [ bpl-react-query ] | [ ![ ] [ bp-swr ]] [ bpl-swr ] | [ ![ ] [ bp-apollo ]] [ bpl-apollo ] |
23
+ | Queries | ✅ | ✅ | ✅ |
24
+ | Caching | ✅ | ✅ | ✅ |
25
+ | Devtools | ✅ | 🟡 | ✅ |
26
+ | Polling/Intervals | ✅ | ✅ | ✅ |
27
+ | Parallel Queries | ✅ | ✅ | ✅ |
28
+ | Dependent Queries | ✅ | ✅ | ✅ |
29
+ | Paginated Queries | ✅ | 🛑<sup >1</sup > | ✅ |
30
+ | Infinite Queries | ✅ | ✅ | ✅ |
31
+ | Initial Data | ✅ | ✅ | ✅ |
32
+ | Scroll Recovery | ✅ | ✅ | ✅ |
33
+ | Cache Manipulation | ✅ | ✅ | ✅ |
34
+ | Outdated Query Dismissal | ✅ | ✅ | ✅ |
35
+ | Auto Garbage Collection | ✅ | 🛑 | 🛑 |
36
+ | Mutation Hooks | ✅ | 🟡 | ✅ |
37
+ | Prefetching APIs | ✅ | 🔶 | ✅ |
38
+ | Query Cancellation | ✅ | 🛑 | 🛑 |
39
+ | Partial Query Matching<sup >2</sup > | ✅ | 🛑 | 🛑 |
40
+ | Window Focus Refetching | ✅ | ✅ | 🛑 |
41
+ | Network Status Refetching | ✅ | ✅ | ✅ |
42
+ | Automatic Refetch after Mutation<sup >3</sup > | 🔶 | 🔶 | ✅ |
43
+ | Cache Dehydration/Rehydration | 🛑 (Coming Soon!) | 🛑 | ✅ |
44
+ | React Suspense (Experimental) | ✅ | ✅ | 🛑 |
45
45
46
46
### Notes
47
47
0 commit comments