Skip to content

Instantly share code, notes, and snippets.

@dainemawer
Last active April 5, 2022 05:35
Show Gist options
  • Save dainemawer/a0adb4e95c52d9b0103d818437c66842 to your computer and use it in GitHub Desktop.
Save dainemawer/a0adb4e95c52d9b0103d818437c66842 to your computer and use it in GitHub Desktop.
Lighthouse Gitlab CLI Config
lhci:
image: cypress/browsers:node16.5.0-chrome94-ff93
script:
- npm ci
- npm run build
- npm install -g @lhci/cli@0.8.x
- lhci autorun --upload.target=temporary-public-storage --collect.staticDistDir="./projects/hola-magazine/.next" --collect.settings.chromeFlags="--no-sandbox" || echo "LHCI failed!"
[
{
"path": "/*",
"timings": [
{
"metric": "interactive",
"budget": 5000
},
{
"metric": "largest-contentful-paint",
"budget": 2500
},
{
"metric": "cumulative-layout-shift",
"budget": 100
}
]
}
]
module.exports = {
ci: {
upload: {
target: 'temporary-public-storage',
},
assert: {
preset: 'lighthouse:recommended',
},
},
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment