1
0
Fork 0
mirror of https://git.sr.ht/~seirdy/seirdy.one synced 2024-11-27 14:12:09 +00:00

CI: Skip unused audits instead of ignoring

This commit is contained in:
Rohan Kumar 2020-12-28 15:32:52 -08:00
parent d429bfad2f
commit bb125c8b9f
No known key found for this signature in database
GPG key ID: 1E892DB2A5F84479

View file

@ -3,7 +3,6 @@ ci:
assert: assert:
preset: lighthouse:recommended preset: lighthouse:recommended
assertions: assertions:
errors-in-console: "off" # false positive for CSP violation
installable-manifest: "off" # not a PWA installable-manifest: "off" # not a PWA
offline-start-url: "off" # not a PWA offline-start-url: "off" # not a PWA
performance-budget: "error" performance-budget: "error"
@ -12,28 +11,20 @@ ci:
# the CSS file. # the CSS file.
# My site doesn't use JS so it doesn't use the recommended async hack # My site doesn't use JS so it doesn't use the recommended async hack
- maxLength: 1 - maxLength: 1
robots-txt: "off" # Lighthouse is incompatible with a hardened CSP
service-worker: "off" # not a PWA
splash-screen: "off" # not a PWA
themed-omnibox: "off" # antifeature, not a PWA
works-offline: "off" # not a PWA. Use caching.
is-crawlable: "off" # staging server won't be indexed
timing-budget: "off" # buggy; manually use the below assertions instead timing-budget: "off" # buggy; manually use the below assertions instead
canonical: "off" # staging server doesn't have canonical
# https://seirdy.one/2020/11/23/website-best-practices.html#about-lazy-loading # https://seirdy.one/2020/11/23/website-best-practices.html#about-lazy-loading
offscreen-images: "off"
speed-index: speed-index:
- warn - warn
- maxNumericValue: 3000 - maxNumericValue: 2000
largest-contentful-paint: largest-contentful-paint:
- warn - warn
- maxNumericValue: 3000 - maxNumericValue: 2000
first-contentful-paint: first-contentful-paint:
- warn - warn
- maxNumericValue: 3000 - maxNumericValue: 2000
first-meaningful-paint: first-meaningful-paint:
- warn - warn
- maxNumericValue: 3000 - maxNumericValue: 2000
total-blocking-time: total-blocking-time:
- warn - warn
- maxNumericValue: 0 - maxNumericValue: 0
@ -46,10 +37,18 @@ ci:
budgetPath: budget.json budgetPath: budget.json
chromeFlags: "--disable-gpu --no-sandbox --disable-extensions --no-first-run --headless" chromeFlags: "--disable-gpu --no-sandbox --disable-extensions --no-first-run --headless"
skipAudits: skipAudits:
- robots-txt - robots-txt # Lighthouse bug: CSP makes this impossible
- canonical - canonical # staging site has no rel=canonical
- is-crawlable # staging site isn't crawlable
- service-worker # not a PWA
- works-offline # not a PWA
- installable-manifest # not a PWA
- splash-screen # not a PWA
- themed-omnibox # not a PWA
- offline-start-url # not a pwa
- offscreen-images # antipattern: see my articlec on best practices for textual websites
throttling: throttling:
cpuSlowdownMultiplier: 3 # seems about right on builds.sr.ht cpuSlowdownMultiplier: 1.2 # seems about right on builds.sr.ht
throttlingMethod: devtools throttlingMethod: devtools
url: url:
- https://staging.seirdy.one/ - https://staging.seirdy.one/