Files
wehub-resource-sync 0af812490d
CI / python (push) Failing after 0s
CI / javascript (push) Failing after 1s
CI / dotnet (push) Failing after 1s
chore: import upstream snapshot with attribution
2026-07-13 12:12:36 +08:00

19 lines
457 B
TypeScript

/**
* Basic CloakBrowser example using Puppeteer API.
*
* Usage:
* CLOAKBROWSER_BINARY_PATH=/path/to/chrome npx tsx examples/basic-puppeteer.ts
*/
import { launch } from "../src/puppeteer.js";
const browser = await launch({ headless: true });
const page = await browser.newPage();
await page.goto("https://example.com");
console.log(`Title: ${await page.title()}`);
console.log(`URL: ${page.url()}`);
await browser.close();
console.log("Done.");