You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/core/api/useQuery.md
+9-5
Original file line number
Diff line number
Diff line change
@@ -13,16 +13,20 @@ import VoteDemo from '../shared/\_VoteDemo.mdx';
13
13
14
14
# useQuery()
15
15
16
-
Query the store.
16
+
Data rendering without the fetch.
17
17
18
-
Renders any [Queryable Schema](/rest/api/schema#queryable) like [Entity](/rest/api/Entity), [All](/rest/api/All), [Collection](/rest/api/Collection), [Query](/rest/api/Query),
19
-
and [Union](/rest/api/Union) from the store.
18
+
Access any [Queryable Schema](/rest/api/schema#queryable)'s store value; like [Entity](/rest/api/Entity), [All](/rest/api/All), [Collection](/rest/api/Collection), [Query](/rest/api/Query),
19
+
and [Union](/rest/api/Union). If the value does not exist, returns `undefined`.
20
+
21
+
`useQuery()` is reactive to data [mutations](../getting-started/mutations.md); rerendering only when necessary. Returns `undefined`
22
+
when data is [Invalid](../concepts/expiry-policy#invalid).
23
+
24
+
:::tip
20
25
21
26
[Queries](/rest/api/Query) are a great companion to efficiently render aggregate computations like those that use [groupBy](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/groupBy#browser_compatibility),
22
27
[map](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/map), [reduce](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/reduce), and [filter](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/filter).
23
28
24
-
`useQuery()` is reactive to data [mutations](../getting-started/mutations.md); rerendering only when necessary. Returns `undefined`
25
-
when data is [Invalid](../concepts/expiry-policy#invalid).
0 commit comments