PortablePosPrinterHamekara/node_modules/webdriver-bidi-protocol
mehranz c2686e7110 initial commit 2025-11-15 13:33:50 +03:30
..
out initial commit 2025-11-15 13:33:50 +03:30
src initial commit 2025-11-15 13:33:50 +03:30
CHANGELOG.md initial commit 2025-11-15 13:33:50 +03:30
LICENSE initial commit 2025-11-15 13:33:50 +03:30
README.md initial commit 2025-11-15 13:33:50 +03:30
package.json initial commit 2025-11-15 13:33:50 +03:30

README.md

webdriver-bidi-protocol

This repository contains TypeScript types conforming to the WebDriver BiDi specification. It also supports WebDriver BiDi extension modules defined in other specifications:

Installation

npm install webdriver-bidi-protocol

Usage

In your TypeScript client implementation, you can now import WebDriver BiDi types:

import {Commands} from 'webdriver-bidi-protocol';

async function sendCommand<T extends keyof Commands>(
  method: T,
  params: Commands[T]['params']
): {result: Commands[T]['returnType']} {
  // Implementation for sending the data using WebSockets.
}

// Now TypeScript validates that the params match the spec for 'browsingContext.print'.
await sendCommand('browsingContext.print', {context: 'xxx'});

Versioning

This package patch version will be incremented whenever there are specification updates.