Audits🧪
Audits 领域允许调查页面违规和可能的改进。
EN
Audits domain allows investigation of page violations and possible improvements.
✅️️ Methods
🔨Audits.checkFormsIssues
对目标页面执行表单问题检查。发现的问题将通过 Audits.issueAdded 事件进行报告。
EN
Runs the form issues check for the target page. Found issues are reported using Audits.issueAdded event.
| 返回对象 | 类型 | 描述 | 原文 |
|---|---|---|---|
| formIssues | array[GenericIssueDetails] |
🔨Audits.disable
禁用问题域,防止进一步的问题报告给客户端。
EN
Disables issues domain, prevents further issues from being reported to the client.
🔨Audits.enable
启用问题域,通过issueAdded事件将迄今为止收集的问题发送给客户端。
EN
Enables issues domain, sends the issues collected so far to the client by means of the
issueAdded event.🔨Audits.getEncodedResponse
如果使用指定设置重新编码,则返回响应体及其大 小。仅适用于图像。
EN
Returns the response body and size if it were re-encoded with the specified settings. Only applies to images.
| 参数 | 必填 | 标记 | 类型 | 描述 | 原文 |
|---|---|---|---|---|---|
| requestId | ✔️ | Network.RequestId | 获取内容的网络请求标识符。 | ENIdentifier of the network request to get content for. | |
| encoding | ✔️ | string | 使用的编码。 允许的值: webp、jpeg、png | ENThe encoding to use.Allowed Values: webp, jpeg, png | |
| quality | number | 编码质量(0-1)。(默认为1) | ENThe quality of the encoding (0-1). (defaults to 1) | ||
| sizeOnly | boolean | 是否仅返回尺寸信息(默认为 false)。 | ENWhether to only return the size information (defaults to false). |
| 返回对象 | 类型 | 描述 | 原文 |
|---|---|---|---|
| body | string | 编码后的主体以base64字符串形式表示。如果sizeOnly为true则省略。(通过JSON传递时编码为base64字符串) | ENThe encoded body as a base64 string. Omitted if sizeOnly is true. (Encoded as a base64 string when passed over JSON) |
| originalSize | integer | 重新编码前的大小。 | ENSize before re-encoding. |
| encodedSize | integer | 重新编码后的大小。 | ENSize after re-encoding. |
✅️️ Events
👋Audits.issueAdded
| 参数 | 必填 | 标记 | 类型 | 描述 | 原文 |
|---|---|---|---|---|---|
| issue | ✔️ | InspectorIssue |