chore(types,base-driver): rename DriverOpts => ServerArgs
these are first and foremost _server_ args, so go with that, except they _also_ get provided to drivers, so we can use the `DriverOpts` alias there.
simplify `tsconfig.json` in `@appium/types`
MODIFY
packages/base-driver/lib/basedriver/core.js
packages/base-driver/lib/basedriver/core.js
@@ -491,7 +491,7 @@ export {DriverCore};
* @typedef {import('@appium/types').W3CCapabilities} W3CCapabilities
* @typedef {import('@appium/types').Driver} Driver
* @typedef {import('@appium/types').Core} Core
- * @typedef {import('@appium/types').DriverOpts} DriverOpts
+ * @typedef {import('@appium/types').ServerArgs} DriverOpts
* @typedef {import('@appium/types').EventHistory} EventHistory
* @typedef {import('@appium/types').AppiumLogger} AppiumLogger
*/

MODIFY
packages/types/lib/config.ts
packages/types/lib/config.ts
@@ -59,7 +59,7 @@ type KeyOrDefaultForProp<Prop extends keyof ServerConfigMapping> =
*
* These will be camel-cased unless overridden by `appiumCliDest` field in schema(s).
*/
-export type DriverOpts = {
+export type ServerArgs = {
[Prop in keyof ServerConfigMapping as SetKeyForProp<Prop>]: KeyOrDefaultForProp<Prop>;
};
// begin utils

MODIFY
packages/types/lib/index.ts
packages/types/lib/index.ts
@@ -3,21 +3,21 @@ import type { EventEmitter } from 'events';
import type { Server } from 'http';
import type { Logger } from 'npmlog';
import type { Class as _Class, MultidimensionalReadonlyArray } from 'type-fest';
-import { DriverOpts } from './config';
+import { ServerArgs } from './config';
import { Capabilities, W3CCapabilities } from './capabilities';
export { AppiumW3CCapabilities } from './capabilities';
export { AppiumConfig, NormalizedAppiumConfig } from './config';
export * from './appium-config';
-export { DriverOpts, Capabilities, W3CCapabilities };
+export { ServerArgs, Capabilities, W3CCapabilities };
/**
* Methods and properties which both `AppiumDriver` and `BaseDriver` inherit.
*/
export interface Core {
sessionId: string | null;
- opts: DriverOpts;
- initialOpts: DriverOpts;
+ opts: ServerArgs;
+ initialOpts: ServerArgs;
caps?: Capabilities;
originalCaps?: W3CCapabilities;
protocol?: string;

MODIFY
packages/types/tsconfig.json
packages/types/tsconfig.json
"@appium/schema": ["../schema"]
}
},
- "include": ["lib/**/*"],
+ "include": ["lib"],
"references": [
{"path": "../schema"}
]

chore(types,base-driver): rename DriverOpts => ServerArgs

- these are first and foremost _server_ args, so go with that, except they _also_ get provided to drivers, so we can use the `DriverOpts` alias there.
- simplify `tsconfig.json` in `@appium/types`