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: src/routes/solid-router/reference/data-apis/query.mdx
+5-5Lines changed: 5 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -77,24 +77,24 @@ export default function User(props) {
77
77
Any user based navigation or link click bypasses this cache.
78
78
Revalidation or new fetch updates the cache.
79
79
80
-
## Cache Keys
80
+
## Query Keys
81
81
82
-
To ensure that the cache keys are consistent and unique, arguments are deterministically serialized using `JSON.stringify`.
82
+
To ensure that the query keys are consistent and unique, arguments are deterministically serialized using `JSON.stringify`.
83
83
Before serialization, key/value pairs in objects are sorted so that the order of properties does not affect the serialization.
84
-
For instance, both `{ name: 'Ryan', awesome: true }` and `{ awesome: true, name: 'Ryan' }` will serialize to the same string so that they produce the same cache key.
84
+
For instance, both `{ name: 'Ryan', awesome: true }` and `{ awesome: true, name: 'Ryan' }` will serialize to the same string so that they produce the same query key.
85
85
86
86
## Return value
87
87
88
88
The return value is a `CachedFunction`, a function that has the same signature as the function you passed to `query`.
89
-
This cached function stores the return value using the cache key.
89
+
This cached function stores the return value using the query key.
90
90
Under most circumstances, this temporarily prevents the passed function from running with the same arguments, even if the created function is called repeatedly.
0 commit comments