@orkestrel/browser 0.0.3 → 0.0.6

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/README.md CHANGED
@@ -4,7 +4,9 @@ A typed [Chrome DevTools Protocol](https://chromedevtools.github.io/devtools-pro
4
4
  browser automation library for the `@orkestrel` line. The environment-agnostic
5
5
  core (`src/core` — `CDPClient` speaking the CDP wire protocol over an injected
6
6
  `CDPTransportInterface`, plus `BrowserContext`, `BrowserPage`, and
7
- `BrowserCodegen`) never touches `node:*` or the DOM; the Node runtime (`src/server`)
7
+ `BrowserFrame`, semantic locators, trusted input, network/HAR controls,
8
+ diagnostics, structured DOM snapshots, and `BrowserCodegen`) never touches
9
+ `node:*` or the DOM; the Node runtime (`src/server`)
8
10
  adapts it with a `WebSocketCDPTransport`, browser process launch/discovery
9
11
  (`node:child_process` + `fetch`), a filesystem screenshot writer, and the
10
12
  `Browser` façade that ties launch → context → page together. Part of the
@@ -18,7 +20,7 @@ npm install @orkestrel/browser
18
20
 
19
21
  ## Requirements
20
22
 
21
- - Node.js >= 24 for the server surface (the core surface is environment-agnostic)
23
+ - Node.js >= 22 for the server surface (the core surface is environment-agnostic)
22
24
  - ESM and CommonJS builds ship for both the core and server entry points
23
25
 
24
26
  ## Usage
@@ -32,6 +34,9 @@ const browser = createBrowser()
32
34
  await browser.connect()
33
35
  const page = await browser.create({ url: 'https://example.com' })
34
36
  await page.click('#submit')
37
+ const frame = await page.frame('checkout')
38
+ await frame?.fill('[name=email]', 'ada@example.com')
39
+ const snapshot = await page.snapshot({ styles: ['display'] })
35
40
  await page.screenshot({ path: 'example.png' })
36
41
  await browser.destroy()
37
42
  ```
@@ -54,12 +59,16 @@ const result = await client.send('Page.navigate', { url: 'https://example.com' }
54
59
  For the full surface — the CDP dispatch core, the `BrowserContext` /
55
60
  `BrowserPage` / `BrowserCodegen` entities, the server transports, and usage
56
61
  patterns — see [`guides/src/browser.md`](guides/src/browser.md).
62
+ The researched Playwright comparison, known semantic limits, and prioritized
63
+ Chromium/CDP roadmap live in
64
+ [`guides/src/playwright.md`](guides/src/playwright.md).
57
65
 
58
66
  ## Package
59
67
 
60
68
  Published with two entry points per the `exports` field in `package.json`:
61
69
  the environment-agnostic core (`.`) — `CDPClient`, `BrowserContext`,
62
- `BrowserPage`, `BrowserCodegen`, `createCDPClient`, `CDPTransportInterface` —
70
+ `BrowserPage`, `BrowserFrame`, DOM snapshot traversal helpers,
71
+ `BrowserCodegen`, `createCDPClient`, `CDPTransportInterface` —
63
72
  and the Node-only server surface (`./server`) — `Browser`, `createBrowser`,
64
73
  `createCDPTransport`, `createScreenshotWriter`, `WebSocketCDPTransport`.
65
74