Running snapshots

Updated Jul 27, 2026
bun run bin/css-view.ts [url] [options]

Common options include:

  • --backend agent-browser or --backend playwright to select the browser backend. When omitted, css-view uses agent-browser if it is on PATH and falls back to Playwright otherwise.
  • --agent-browser-session to choose the session name used by the agent-browser backend. The default is css-view.
  • --use-current-page to snapshot the active page in the selected agent-browser session without navigating.
  • --mode cdp or --mode walker to choose the capture mode. The agent-browser backend uses CDP; Playwright defaults to walker mode.
  • --props or --props-file to override the computed-style whitelist.
  • --cdp-url to attach CDP mode to an existing Chromium debugging endpoint and bypass backend selection.
  • --inherited or --inherited-file (walker only) to override inheritance comparisons.
  • --wait-until to pick the navigation lifecycle (load, domcontentloaded, or networkidle).
  • --output to write JSON to a file rather than standard output.
  • --pretty to format JSON for easier inspection.

Refer to docs/css-view.md for the full option matrix and payload schema.