googleads / publisher-ads-lighthouse-plugin

Publisher Ads Audits for Lighthouse is a tool to improve ad speed and overall quality through a series of automated audits. This tool will aid in resolving discovered problems, providing a tool to be used to evaluate effectiveness of iterative changes while suggesting actionable feedback.
https://developers.google.com/publisher-ads-audits
Apache License 2.0
98 stars 45 forks source link
audit best-practices lighthouse lighthouse-audits performance-analysis web

Publisher Ads Audits for Lighthouse

Linux Build Status NPM lighthouse package

Publisher Ads Audits for Lighthouse is a tool to improve ad speed and overall quality through a series of automated audits. At the moment, this is primarily targeted at sites using Google Ad Manager. This tool will aid in resolving discovered problems, providing a tool to be used to evaluate effectiveness of iterative changes while suggesting actionable feedback.

This tool is a plugin for Lighthouse, an open-sourced tool integrated into Chrome dev tools that is widely used by developers.

In order to help us improve please file an issue to let us know of any issues or suggestions you may have.

:warning: Publisher Ads Audits for Lighthouse audit results aren't an indication of compliance or non-compliance with any Google Publisher Policies.

Web App

We currently have a web app version of Publisher Ads Audits for Lighthouse. It can be accessed at developers.google.com/publisher-ads-audits.

Lighthouse Node CLI

Publisher Ads Audits is available as a node package which can be used with the Lighthouse CLI.

Setup

mkdir pub-ads-audits-wrapper && cd pub-ads-audits-wrapper && \
npm init -y && \
yarn add -D lighthouse && \
yarn add -D lighthouse-plugin-publisher-ads

Usage

From within wrapper directory

yarn lighthouse {url} --plugins=lighthouse-plugin-publisher-ads

See Lighthouse documentation for additional options.

Development

Setup

git clone git@github.com:googleads/publisher-ads-lighthouse-plugin.git
cd publisher-ads-lighthouse-plugin
yarn

Usage

node index.js <url>

Available options:

Some common options are:

Continuous Integration

This plugin can be integrated with your existing CI using Lighthouse CI to ensure that ad performance hasn't regressed. Learn More.

Tests

# Lint and test all files.
yarn test

Contributions

See CONTRIBUTING.md

References