Files
appium/packages/base-plugin/lib
Christopher Hiller 0dcd5fa371 fix(base-driver,base-plugin,types): update PluginCommand and DriverCommand types
The first arg of `PluginCommand` is a `NextPluginCallback` which now returns `Promise<unknown>` instead of `Promise<void>`, which was incorrect.

We use `unknown` rather than `any` because it forces us to be explicit about the return value of `await next()` if we are to call it.

Added a type `DriverCommandToPluginCommand` which essentially converts a `DriverCommand` to a `PluginCommand`.  It's probably best used as a type guard or decorator, but it can "fill in the blanks" when overloading commands in a plugin.

Also normalized some of the `TArgs`/`TReturn` stuff.
2023-03-27 14:23:25 -07:00
..