@wix/sdk-types 1.2.2 → 1.2.4
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/build/index.d.mts +3 -13
- package/build/index.d.ts +3 -13
- package/package.json +2 -2
package/build/index.d.mts
CHANGED
|
@@ -1,18 +1,8 @@
|
|
|
1
|
-
type HostModule<T,
|
|
1
|
+
type HostModule<T, Host> = {
|
|
2
2
|
__type: 'host';
|
|
3
|
-
create(host:
|
|
3
|
+
create(host: Host): T;
|
|
4
4
|
};
|
|
5
5
|
type HostModuleAPI<T extends HostModule<any, any>> = T extends HostModule<infer U, any> ? U : never;
|
|
6
|
-
type Host<Environment = unknown> = {
|
|
7
|
-
channel: {
|
|
8
|
-
observeEnvironment(callback: (environment: Environment) => unknown): {
|
|
9
|
-
disconnect: () => void;
|
|
10
|
-
} | Promise<{
|
|
11
|
-
disconnect: () => void;
|
|
12
|
-
}>;
|
|
13
|
-
};
|
|
14
|
-
environment?: Environment;
|
|
15
|
-
};
|
|
16
6
|
|
|
17
7
|
type RESTFunctionDescriptor<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient) => T;
|
|
18
8
|
interface HttpClient {
|
|
@@ -45,4 +35,4 @@ type AuthenticationStrategy<Host = unknown> = {
|
|
|
45
35
|
}>;
|
|
46
36
|
};
|
|
47
37
|
|
|
48
|
-
export { APIMetadata, AuthenticationStrategy, BuildRESTFunction,
|
|
38
|
+
export { APIMetadata, AuthenticationStrategy, BuildRESTFunction, HostModule, HostModuleAPI, HttpClient, HttpResponse, RESTFunctionDescriptor, RequestOptions, RequestOptionsFactory };
|
package/build/index.d.ts
CHANGED
|
@@ -1,18 +1,8 @@
|
|
|
1
|
-
type HostModule<T,
|
|
1
|
+
type HostModule<T, Host> = {
|
|
2
2
|
__type: 'host';
|
|
3
|
-
create(host:
|
|
3
|
+
create(host: Host): T;
|
|
4
4
|
};
|
|
5
5
|
type HostModuleAPI<T extends HostModule<any, any>> = T extends HostModule<infer U, any> ? U : never;
|
|
6
|
-
type Host<Environment = unknown> = {
|
|
7
|
-
channel: {
|
|
8
|
-
observeEnvironment(callback: (environment: Environment) => unknown): {
|
|
9
|
-
disconnect: () => void;
|
|
10
|
-
} | Promise<{
|
|
11
|
-
disconnect: () => void;
|
|
12
|
-
}>;
|
|
13
|
-
};
|
|
14
|
-
environment?: Environment;
|
|
15
|
-
};
|
|
16
6
|
|
|
17
7
|
type RESTFunctionDescriptor<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient) => T;
|
|
18
8
|
interface HttpClient {
|
|
@@ -45,4 +35,4 @@ type AuthenticationStrategy<Host = unknown> = {
|
|
|
45
35
|
}>;
|
|
46
36
|
};
|
|
47
37
|
|
|
48
|
-
export { APIMetadata, AuthenticationStrategy, BuildRESTFunction,
|
|
38
|
+
export { APIMetadata, AuthenticationStrategy, BuildRESTFunction, HostModule, HostModuleAPI, HttpClient, HttpResponse, RESTFunctionDescriptor, RequestOptions, RequestOptionsFactory };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wix/sdk-types",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.4",
|
|
4
4
|
"license": "UNLICENSED",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Ronny Ringel",
|
|
@@ -60,5 +60,5 @@
|
|
|
60
60
|
"wallaby": {
|
|
61
61
|
"autoDetect": true
|
|
62
62
|
},
|
|
63
|
-
"falconPackageHash": "
|
|
63
|
+
"falconPackageHash": "97d8b69d010548674ae4be8665fe629d7f95f8dfdfdceb9e0586939b"
|
|
64
64
|
}
|