Introducció
Astral …
deno init astralcd astraldeno add add jsr:@astral/astral// Import Astralimport { launch } from "@astral/astral"
// Launch the browser await using browser = await launch();
// Open a new page await using page = await browser.newPage("https://deno.land");
// Take a screenshot of the page and save that to diskconst screenshot = await page.screenshot();Deno.writeFileSync("screenshot.png", screenshot);
// Clean up is performed automaticallydeno run --allow-all .\screenshot.ts