Skip to main content
Version: 23.10.1

install() 函数

¥install() function

install():Promise<InstalledBrowser>

根据 InstallOptions 下载并解压浏览器存档。

¥Downloads and unpacks the browser archive according to the InstallOptions.

签名

¥Signature

export declare function install(
options: InstallOptions & {
unpack?: true;
},
): Promise<InstalledBrowser>;

参数

¥Parameters

范围

类型

描述

options

InstallOptions & { unpack?: true; }

Returns:

Promise<InstalledBrowser>

InstalledBrowser 实例。

¥a InstalledBrowser instance.

install():Promise<string>

根据 InstallOptions 下载浏览器存档而不解压。

¥Downloads the browser archive according to the InstallOptions without unpacking.

签名

¥Signature

export declare function install(
options: InstallOptions & {
unpack: false;
},
): Promise<string>;

参数

¥Parameters

范围

类型

描述

options

InstallOptions & { unpack: false; }

Returns:

Promise<string>

存档的绝对路径。

¥the absolute path to the archive.