mirror of
https://github.com/jcreek/LivingDexTracker.git
synced 2026-09-16 10:32:10 +00:00
perf: fix slow page loads and gate performance in CI
- Ship one hashed Tailwind stylesheet instead of two (one render-blocking) - Compress responses in-app (brotli/gzip, streaming-safe) and precompress the node build so local and CI measurements match production - Validate the Supabase session once per request - Render the homepage immediately and stream public stats - Stream a Pokedex's entries with the page instead of fetching after hydration, running the rows and count queries in parallel - Shrink the avatar and offline placeholder images, fix layout shift, contrast, link names and missing meta descriptions - Add Lighthouse CI (mobile + desktop) with score and metric budgets, bundle-size budgets in the build tests, and signed-in speed scenarios
This commit is contained in:
+9
-4
@@ -1,9 +1,9 @@
|
||||
/** @type {import('tailwindcss').Config} */
|
||||
export default {
|
||||
content: [
|
||||
'./src/routes/**/*.{svelte,js,ts}',
|
||||
'./src/routes/**/**/*.{svelte,js,ts}',
|
||||
'./src/lib/components/**/*.{svelte,js,ts}'
|
||||
'./src/**/*.{html,svelte,js,ts}',
|
||||
'./static/offline.html',
|
||||
'./static/offline-viewer.js'
|
||||
],
|
||||
theme: {
|
||||
extend: {}
|
||||
@@ -16,11 +16,16 @@ export default {
|
||||
'dracula',
|
||||
{
|
||||
pokeball: {
|
||||
primary: '#ee1515',
|
||||
// A slightly deeper Poké Ball red: #ee1515 gave white text only 4.3:1 contrast, below
|
||||
// the WCAG AA 4.5:1 minimum that the Lighthouse accessibility gate checks.
|
||||
primary: '#d31111',
|
||||
'primary-content': '#ffffff',
|
||||
secondary: '#ffd700',
|
||||
'secondary-content': '#ffffff',
|
||||
accent: '#3b82c4',
|
||||
// daisyUI's default info blue is too light for text on the base colours.
|
||||
info: '#0369a1',
|
||||
'info-content': '#ffffff',
|
||||
neutral: '#ffffff',
|
||||
'base-100': '#f0f0f0',
|
||||
'base-content': '#222224'
|
||||
|
||||
Reference in New Issue
Block a user