/** @type {import('lighthouse').Config} */ module.exports = { ci: { collect: { url: ['http://localhost:3000'], numberOfRuns: 3, startServerCommand: 'npm run start', startServerReadyPattern: 'ready', startServerReadyTimeout: 30000, }, assert: { assertions: { 'categories:performance': ['error', { minScore: 1 }], 'categories:accessibility': ['error', { minScore: 1 }], 'categories:best-practices': ['error', { minScore: 1 }], 'categories:seo': ['error', { minScore: 1 }], // Core Web Vitals 'first-contentful-paint': ['error', { maxNumericValue: 1800 }], 'largest-contentful-paint': ['error', { maxNumericValue: 2500 }], 'cumulative-layout-shift': ['error', { maxNumericValue: 0.1 }], 'total-blocking-time': ['error', { maxNumericValue: 200 }], 'speed-index': ['error', { maxNumericValue: 3400 }], // Performance metrics 'interactive': ['error', { maxNumericValue: 3800 }], 'uses-optimized-images': 'error', 'uses-text-compression': 'error', 'uses-responsive-images': 'error', 'modern-image-formats': 'error', 'offscreen-images': 'error', 'render-blocking-resources': 'error', 'unused-css-rules': 'error', 'unused-javascript': 'error', 'efficient-animated-content': 'error', 'preload-lcp-image': 'error', 'uses-long-cache-ttl': 'error', 'total-byte-weight': ['error', { maxNumericValue: 1600000 }], }, }, upload: { target: 'temporary-public-storage', }, }, };