ShotPage

tcmts.cli.shot.ShotPage · #epzpf7fw · interface

What tcm shot uses of Playwright's page.

export interface ShotPage {
  on(event: string, fn: (x: any) => void): void;
  goto(
    url: string,
    o: { waitUntil: "load"; timeout: number },
  ): Promise<{ status(): number } | null>;
  waitForLoadState(state: "networkidle", o: { timeout: number }): Promise<void>;
  evaluate(expression: string): Promise<unknown>;
  waitForTimeout(ms: number): Promise<void>;
  title(): Promise<string>;
  screenshot(o: { path: string; fullPage: boolean }): Promise<Uint8Array>;
}

used by