当前位置:网站首页>puppeteer入门之 Page 类
puppeteer入门之 Page 类
2022-06-12 16:03:00 【crayon-shin-chan】
文档:puppeteer/api.md at main · puppeteer/puppeteer · GitHub
1.简介
Page 提供了与 Chromium 中的单个选项卡或扩展背景页面交互的方法。
一个Browser实例可能有多个Page实例。
const puppeteer = require('puppeteer');
(async () => {
const browser = await puppeteer.launch();
const page = await browser.newPage();
await page.goto('https://example.com');
await page.screenshot({ path: 'screenshot.png' });
await browser.close();
})();2.事件
page可以响应以下事件
export declare interface PageEventObject {
close: never;
console: ConsoleMessage;
dialog: Dialog;
domcontentloaded: never;
error: Error;
frameattached:边栏推荐
- Redis General Command
- Office VR porn, coquettish operation! The father of Microsoft hololens resigns!
- mysql Blob和Text类型
- 一步步创建包含自定义 Screen 的 ABAP 程序的详细步骤
- 远程操控其它电脑--详细教程
- Scanpy(六)空间转录组数据的分析与可视化
- Defer learning in golang
- Design concept of ORM framework
- Servlet knowledge explanation (2)
- org. xml. sax. SAXParseException; lineNumber: 63; columnNumber: 10; The definition of "mapper" in the related type must be matched with "(CAC
猜你喜欢

远程操控其它电脑--详细教程

Unicom Network Management Protocol block diagram

Servlet knowledge explanation (2)

Project training of Software College of Shandong University rendering engine system radiation pre calculation (VIII)

Project training of Software College of Shandong University rendering engine system radiation pre calculation (IX)

Broadcast and multicast (tcp/ip details volume 1/2)

< 山东大学软件学院项目实训 > 渲染引擎系统——基础渲染器(三)

When programming is included in the college entrance examination...

IGMP message (tcp/ip details volume 1/ Volume 2)

Understanding of dart typedef
随机推荐
Project training of Software College of Shandong University rendering engine system basic renderer (VII)
Use of thread communication
Development practice of ag1280q48 in domestic CPLD
jupyter notebook新环境快捷方式
广播和多播(TCP/IP详解卷1/2)
Interface.
< 山东大学软件学院项目实训 > 渲染引擎系统——基础渲染器(四)
redis 通用命令
nohup 命令使用
Remote control of other computers -- detailed tutorial
Saga体系结构模式:微服务架构下跨服务事务的实现
Daily leetcode - 3 Longest substring without duplicate characters
With a lamp inserted in the nostril, the IQ has risen and become popular in Silicon Valley. 30000 yuan is enough
为什么阿里巴巴不建议MySQL使用Text类型?
TS 22.011
< 山东大学软件学院项目实训 > 渲染引擎系统——基础渲染器(五)
联通网管协议框图
Project training of Software College of Shandong University rendering engine system basic renderer (IV)
< 山东大学软件学院项目实训 > 渲染引擎系统——点云处理(十)
小程序:如何在插件中获取用户手机号