系统要求
Node 版本、TypeScript 版本,以及 Chrome for Testing 与 Firefox 在各平台上运行所需的系统依赖。
本篇目录与全部章节
Node 与 TypeScript
- Node 22.12+。Puppeteer 跟随 Node 最新的 maintenance LTS 版本。
- TypeScript 5.0.1+(如果使用 TypeScript)。
- 如果你要对
node_modules做类型检查,target 需要设为 ES2022 或更高。
- 如果你要对
Chrome
Chrome for Testing 浏览器的系统要求:
- Windows:x64 架构。
- macOS:x64 与 arm64 架构。
- Debian/Ubuntu Linux:x64 与 arm64 架构。
- 所需的系统包见 dist_package_versions.json。
- openSUSE/Fedora Linux:x64 与 arm64 架构。
- 所需的系统包见 dist_package_provides.json。
- 在 Windows 上需要
tar.exe或 PowerShell、在 macOS/Linux 上需要unzip来解包 Chrome for Testing 二进制,除非安装了可选的yauzl依赖。
Firefox
Firefox 浏览器的系统要求:
- 见 https://www.mozilla.org/en-US/firefox/system-requirements/。
- 在 Linux 上解包 Firefox 版本需要
xz或bzip2工具。
译自pptr.dev/guides/system-requirements,对应 Puppeteer v25.14.0