From 4fc63bc304b706c4b959222de855164827e5bc0c Mon Sep 17 00:00:00 2001 From: Nicolas Bastien Date: Wed, 25 May 2022 14:33:22 +0200 Subject: [PATCH] Bot : add google page speed To be able to test on https://pagespeed.web.dev/ --- src/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/index.js b/src/index.js index a095edd..6ce341f 100644 --- a/src/index.js +++ b/src/index.js @@ -6,7 +6,7 @@ export default { return dummyEl } - const botRegex = regex || /bot|googlebot|crawler|spider|robot|crawling/i + const botRegex = regex || /bot|googlebot|crawler|spider|robot|crawling|Chrome-Lighthouse/i const isBot = navigator.userAgent && botRegex.test(navigator.userAgent) const shouldShow = invert ? isBot : !isBot