@triplit/svelte 0.1.6 → 0.1.8
Sign up to get free protection for your applications and to get access to all the features.
- package/CHANGELOG.md +13 -0
- package/dist/index.svelte.d.ts +1 -1
- package/dist/index.svelte.js +2 -2
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
package/dist/index.svelte.d.ts
CHANGED
@@ -7,5 +7,5 @@ export declare function useQuery<M extends Models<any, any> | undefined, CN exte
|
|
7
7
|
updateQuery: (query: ClientQueryBuilder<M, CN>) => void;
|
8
8
|
};
|
9
9
|
export declare function useConnectionStatus(client: TriplitClient<any>): {
|
10
|
-
readonly status:
|
10
|
+
readonly status: string;
|
11
11
|
};
|
package/dist/index.svelte.js
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
export function useQuery(client, query, options) {
|
3
3
|
let results = $state(undefined);
|
4
4
|
let fetching = $state(false);
|
5
|
-
let fetchingRemote = $state(client.syncEngine.connectionStatus
|
5
|
+
let fetchingRemote = $state(client.syncEngine.connectionStatus !== 'CLOSED');
|
6
6
|
let error = $state(undefined);
|
7
7
|
let hasResponseFromServer = false;
|
8
8
|
let builtQuery = $state(query && query.build());
|
@@ -63,7 +63,7 @@ export function useQuery(client, query, options) {
|
|
63
63
|
};
|
64
64
|
}
|
65
65
|
export function useConnectionStatus(client) {
|
66
|
-
let status = $state(
|
66
|
+
let status = $state('CONNECTING');
|
67
67
|
$effect(() => {
|
68
68
|
const unsub = client.syncEngine.onConnectionStatusChange((newStatus) => {
|
69
69
|
status = newStatus;
|
package/package.json
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "@triplit/svelte",
|
3
3
|
"packageManager": "yarn@3.4.1",
|
4
|
-
"version": "0.1.
|
4
|
+
"version": "0.1.8",
|
5
5
|
"source": "./src/index.svelte.ts",
|
6
6
|
"main": "./dist/index.svelte.js",
|
7
7
|
"module": "./dist/index.svelte.js",
|
@@ -27,7 +27,7 @@
|
|
27
27
|
"/dist"
|
28
28
|
],
|
29
29
|
"dependencies": {
|
30
|
-
"@triplit/client": "^0.3.
|
30
|
+
"@triplit/client": "^0.3.36"
|
31
31
|
},
|
32
32
|
"devDependencies": {
|
33
33
|
"@sveltejs/package": "^2.3.0",
|