GoogleChrome / lighthouse-ci

Automate running Lighthouse for every commit, viewing the changes, and preventing regressions
Apache License 2.0
6.33k stars 633 forks source link

feat(cli): add static dir file discovery depth flag #940

Closed DanielSwarup closed 6 months ago

DanielSwarup commented 10 months ago

Reason For this feature: When I ran lhci autorun on my static site folder which has deeper folders with index.html it did not recognise them after a depth of 2 folders. This is because LHCI currently hard caps it at a depth of 2. I hope the example in the docs changed file explains it.

(This is my first open-source contribution ever. Thank you for this amazing repo!)

connorjclark commented 6 months ago

Thanks!

I'm not sure why we have this limit in the first place ... but if we must have it, making it configurable is cool.

DanielSwarup commented 6 months ago

Thanks for fixing the linting error! I'll take a look at this test error and push asap.

connorjclark commented 6 months ago

You should just need to run yarn test:unit -u to update the snapshot tests.

DanielSwarup commented 6 months ago

Weirdly enough I've got a bunch of snapshots failing cause chromium is acting up. Could you please update the snapshot? Apologies and thank you!