@webiny/handler-client 5.21.0 → 5.22.0-beta.0

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,8 +1,7 @@
1
- import { Context } from "@webiny/handler/types";
2
- import { HandlerClientPlugin, InvokeArgs } from "./types";
1
+ import { InvokeArgs, ClientContext } from "./types";
3
2
  declare class HandlerClient {
4
- plugin: HandlerClientPlugin;
5
- constructor(context: Context);
3
+ private readonly plugin;
4
+ constructor(context: ClientContext);
6
5
  invoke<TInvokeArgsPayload = any, TResponse = any>(params: InvokeArgs<TInvokeArgsPayload>): Promise<TResponse>;
7
6
  }
8
7
  export default HandlerClient;
package/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
- import { Context } from "@webiny/handler/types";
1
+ import { ClientContext } from "./types";
2
2
  declare const _default: () => {
3
3
  type: string;
4
- apply(context: Context): void;
4
+ apply(context: ClientContext): void;
5
5
  };
6
6
  export default _default;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@webiny/handler-client",
3
- "version": "5.21.0",
3
+ "version": "5.22.0-beta.0",
4
4
  "main": "index.js",
5
5
  "repository": {
6
6
  "type": "git",
@@ -14,18 +14,18 @@
14
14
  ],
15
15
  "license": "MIT",
16
16
  "dependencies": {
17
- "@babel/runtime": "7.16.3",
18
- "@webiny/error": "5.21.0",
19
- "@webiny/handler": "5.21.0",
20
- "@webiny/plugins": "5.21.0"
17
+ "@babel/runtime": "7.16.7",
18
+ "@webiny/error": "5.22.0-beta.0",
19
+ "@webiny/handler": "5.22.0-beta.0",
20
+ "@webiny/plugins": "5.22.0-beta.0"
21
21
  },
22
22
  "devDependencies": {
23
- "@babel/cli": "^7.5.5",
24
- "@babel/core": "^7.5.5",
25
- "@babel/preset-env": "^7.5.5",
26
- "@babel/preset-typescript": "^7.8.3",
27
- "@webiny/cli": "^5.21.0",
28
- "@webiny/project-utils": "^5.21.0",
23
+ "@babel/cli": "^7.16.0",
24
+ "@babel/core": "^7.16.0",
25
+ "@babel/preset-env": "^7.16.4",
26
+ "@babel/preset-typescript": "^7.16.0",
27
+ "@webiny/cli": "^5.22.0-beta.0",
28
+ "@webiny/project-utils": "^5.22.0-beta.0",
29
29
  "babel-plugin-lodash": "^3.3.4",
30
30
  "jest": "^26.6.3",
31
31
  "merge": "^1.2.1",
@@ -40,5 +40,5 @@
40
40
  "build": "yarn webiny run build",
41
41
  "watch": "yarn webiny run watch"
42
42
  },
43
- "gitHead": "c3d4955bf74e7ffdb9628867e3b23cdfe64ea8dc"
43
+ "gitHead": "487330472a07000c4845340f3b3dfa6b3ae98944"
44
44
  }
package/types.d.ts CHANGED
@@ -1,5 +1,6 @@
1
1
  import HandlerClient from "./HandlerClient";
2
2
  import { Plugin } from "@webiny/plugins/types";
3
+ import { Context } from "@webiny/handler/types";
3
4
  export declare type InvokeArgs<TInvokeArgsPayload = any> = {
4
5
  name: string;
5
6
  payload?: TInvokeArgsPayload;
@@ -14,6 +15,6 @@ export declare type HandlerClientHandlerPlugin = Plugin & {
14
15
  type: "handler-client-handler";
15
16
  invoke: <TArgs = Record<string, any>, TResponse = Record<string, any>>(params: TArgs) => TResponse | Promise<TResponse>;
16
17
  };
17
- export declare type ClientContext = {
18
+ export interface ClientContext extends Context {
18
19
  handlerClient: HandlerClient;
19
- };
20
+ }