@tanstack/solid-query 5.0.0-alpha.84 → 5.0.0-alpha.85
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +2 -2
- package/src/__tests__/utils.tsx +5 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tanstack/solid-query",
|
|
3
|
-
"version": "5.0.0-alpha.
|
|
3
|
+
"version": "5.0.0-alpha.85",
|
|
4
4
|
"description": "Primitives for managing, caching and syncing asynchronous and remote data in Solid",
|
|
5
5
|
"author": "tannerlinsley",
|
|
6
6
|
"license": "MIT",
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
"src"
|
|
37
37
|
],
|
|
38
38
|
"dependencies": {
|
|
39
|
-
"@tanstack/query-core": "5.0.0-alpha.
|
|
39
|
+
"@tanstack/query-core": "5.0.0-alpha.85"
|
|
40
40
|
},
|
|
41
41
|
"devDependencies": {
|
|
42
42
|
"vite-plugin-solid": "^2.5.0"
|
package/src/__tests__/utils.tsx
CHANGED
|
@@ -3,6 +3,7 @@ import { vi } from 'vitest'
|
|
|
3
3
|
import { QueryClient } from '../QueryClient'
|
|
4
4
|
import type { QueryClientConfig } from '@tanstack/query-core'
|
|
5
5
|
import type { ParentProps } from 'solid-js'
|
|
6
|
+
import type { SpyInstance } from 'vitest'
|
|
6
7
|
|
|
7
8
|
let queryKeyCount = 0
|
|
8
9
|
export function queryKey(): Array<string> {
|
|
@@ -34,11 +35,13 @@ export function createQueryClient(config?: QueryClientConfig): QueryClient {
|
|
|
34
35
|
return new QueryClient(config)
|
|
35
36
|
}
|
|
36
37
|
|
|
37
|
-
export function mockVisibilityState(
|
|
38
|
+
export function mockVisibilityState(
|
|
39
|
+
value: DocumentVisibilityState,
|
|
40
|
+
): SpyInstance<[], DocumentVisibilityState> {
|
|
38
41
|
return vi.spyOn(document, 'visibilityState', 'get').mockReturnValue(value)
|
|
39
42
|
}
|
|
40
43
|
|
|
41
|
-
export function mockNavigatorOnLine(value: boolean) {
|
|
44
|
+
export function mockNavigatorOnLine(value: boolean): SpyInstance<[], boolean> {
|
|
42
45
|
return vi.spyOn(navigator, 'onLine', 'get').mockReturnValue(value)
|
|
43
46
|
}
|
|
44
47
|
|