houdini-svelte 1.0.0-next.10 → 1.0.0-next.11
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.
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { DocumentStore } from '$houdini/runtime/client';
|
|
2
|
-
import type { MutationArtifact, GraphQLObject } from '$houdini/runtime/lib/types';
|
|
2
|
+
import type { MutationArtifact, GraphQLObject, QueryResult } from '$houdini/runtime/lib/types';
|
|
3
3
|
import type { RequestEvent } from '@sveltejs/kit';
|
|
4
4
|
import { BaseStore } from './base';
|
|
5
5
|
export declare class MutationStore<_Data extends GraphQLObject, _Input extends {}, _Optimistic extends GraphQLObject> extends BaseStore<_Data, _Input, MutationArtifact> {
|
|
@@ -8,7 +8,7 @@ export declare class MutationStore<_Data extends GraphQLObject, _Input extends {
|
|
|
8
8
|
metadata?: App.Metadata;
|
|
9
9
|
fetch?: typeof globalThis.fetch;
|
|
10
10
|
event?: RequestEvent;
|
|
11
|
-
} & MutationConfig<_Data, _Input, _Optimistic>): Promise<_Data
|
|
11
|
+
} & MutationConfig<_Data, _Input, _Optimistic>): Promise<QueryResult<_Data, _Input>>;
|
|
12
12
|
subscribe(...args: Parameters<DocumentStore<_Data, _Input>['subscribe']>): import("$houdini/runtime/lib").Unsubscriber;
|
|
13
13
|
}
|
|
14
14
|
export type MutationConfig<_Result, _Input, _Optimistic> = {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { DocumentStore } from '$houdini/runtime/client';
|
|
2
|
-
import type { MutationArtifact, GraphQLObject } from '$houdini/runtime/lib/types';
|
|
2
|
+
import type { MutationArtifact, GraphQLObject, QueryResult } from '$houdini/runtime/lib/types';
|
|
3
3
|
import type { RequestEvent } from '@sveltejs/kit';
|
|
4
4
|
import { BaseStore } from './base';
|
|
5
5
|
export declare class MutationStore<_Data extends GraphQLObject, _Input extends {}, _Optimistic extends GraphQLObject> extends BaseStore<_Data, _Input, MutationArtifact> {
|
|
@@ -8,7 +8,7 @@ export declare class MutationStore<_Data extends GraphQLObject, _Input extends {
|
|
|
8
8
|
metadata?: App.Metadata;
|
|
9
9
|
fetch?: typeof globalThis.fetch;
|
|
10
10
|
event?: RequestEvent;
|
|
11
|
-
} & MutationConfig<_Data, _Input, _Optimistic>): Promise<_Data
|
|
11
|
+
} & MutationConfig<_Data, _Input, _Optimistic>): Promise<QueryResult<_Data, _Input>>;
|
|
12
12
|
subscribe(...args: Parameters<DocumentStore<_Data, _Input>['subscribe']>): import("$houdini/runtime/lib").Unsubscriber;
|
|
13
13
|
}
|
|
14
14
|
export type MutationConfig<_Result, _Input, _Optimistic> = {
|
|
@@ -38,7 +38,7 @@ class MutationStore extends import_base.BaseStore {
|
|
|
38
38
|
metadata,
|
|
39
39
|
event
|
|
40
40
|
});
|
|
41
|
-
return
|
|
41
|
+
return await this.observer.send({
|
|
42
42
|
variables,
|
|
43
43
|
fetch: context.fetch,
|
|
44
44
|
metadata,
|
|
@@ -46,7 +46,7 @@ class MutationStore extends import_base.BaseStore {
|
|
|
46
46
|
stuff: {
|
|
47
47
|
...mutationConfig
|
|
48
48
|
}
|
|
49
|
-
})
|
|
49
|
+
});
|
|
50
50
|
}
|
|
51
51
|
subscribe(...args) {
|
|
52
52
|
return this.observer.subscribe(...args);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { DocumentStore } from '$houdini/runtime/client';
|
|
2
|
-
import type { MutationArtifact, GraphQLObject } from '$houdini/runtime/lib/types';
|
|
2
|
+
import type { MutationArtifact, GraphQLObject, QueryResult } from '$houdini/runtime/lib/types';
|
|
3
3
|
import type { RequestEvent } from '@sveltejs/kit';
|
|
4
4
|
import { BaseStore } from './base';
|
|
5
5
|
export declare class MutationStore<_Data extends GraphQLObject, _Input extends {}, _Optimistic extends GraphQLObject> extends BaseStore<_Data, _Input, MutationArtifact> {
|
|
@@ -8,7 +8,7 @@ export declare class MutationStore<_Data extends GraphQLObject, _Input extends {
|
|
|
8
8
|
metadata?: App.Metadata;
|
|
9
9
|
fetch?: typeof globalThis.fetch;
|
|
10
10
|
event?: RequestEvent;
|
|
11
|
-
} & MutationConfig<_Data, _Input, _Optimistic>): Promise<_Data
|
|
11
|
+
} & MutationConfig<_Data, _Input, _Optimistic>): Promise<QueryResult<_Data, _Input>>;
|
|
12
12
|
subscribe(...args: Parameters<DocumentStore<_Data, _Input>['subscribe']>): import("$houdini/runtime/lib").Unsubscriber;
|
|
13
13
|
}
|
|
14
14
|
export type MutationConfig<_Result, _Input, _Optimistic> = {
|
|
@@ -15,7 +15,7 @@ class MutationStore extends BaseStore {
|
|
|
15
15
|
metadata,
|
|
16
16
|
event
|
|
17
17
|
});
|
|
18
|
-
return
|
|
18
|
+
return await this.observer.send({
|
|
19
19
|
variables,
|
|
20
20
|
fetch: context.fetch,
|
|
21
21
|
metadata,
|
|
@@ -23,7 +23,7 @@ class MutationStore extends BaseStore {
|
|
|
23
23
|
stuff: {
|
|
24
24
|
...mutationConfig
|
|
25
25
|
}
|
|
26
|
-
})
|
|
26
|
+
});
|
|
27
27
|
}
|
|
28
28
|
subscribe(...args) {
|
|
29
29
|
return this.observer.subscribe(...args);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "houdini-svelte",
|
|
3
|
-
"version": "1.0.0-next.
|
|
3
|
+
"version": "1.0.0-next.11",
|
|
4
4
|
"description": "The svelte plugin for houdini",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"typescript",
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
"recast": "^0.23.1",
|
|
32
32
|
"svelte": "^3.55.1",
|
|
33
33
|
"vite": "^4.0.4",
|
|
34
|
-
"houdini": "^1.0.0-next.
|
|
34
|
+
"houdini": "^1.0.0-next.11"
|
|
35
35
|
},
|
|
36
36
|
"files": [
|
|
37
37
|
"build"
|