I like to run Lighthouse as part of my CI/CD workflow, which works really well. Although I block my analytics scripts as to not impact our data in any meaningful way and I get the followings errors under best practises:
/gtag/js?id=UA-123…-1(www.googletagmanager.com) | Failed to load resource: net::ERR_BLOCKED_BY_CLIENT
Alongside a few more. Is there a way to whitelist/blacklist certain errors so it doesn't negative impact the stats? I know it's not the biggest deal, but a bit annoying how it stops us from getting 100 across the board ;)
This is not currently possible, but the door is open for this functionality to be added via custom configs in the future.
Side note: awesome that you're having success running Lighthouse in your CI/CD workflow! We'd love to hear your feedback on what was easy/difficult and any thoughts you might have on https://github.com/GoogleChrome/lighthouse-ci as we shape its future :)
I actually didn't set up the integration using lighthouse-ci, it's an integration that I configured through DebugBear. It hosts the ci server for you so it's very easy to set up!
Also, I just thought about an edge case here. I guess this custom config should also apply to the warning in the preconnect links also, since this is not aware that I am blocking this domain either.
Preconnect to required origins
Warnings: A preconnect was found for "https://blocked.domain.com" but was not used by the browser. Check that you are using thecrossoriginattribute properly.
Most helpful comment
I actually didn't set up the integration using lighthouse-ci, it's an integration that I configured through DebugBear. It hosts the ci server for you so it's very easy to set up!