From 12cc719357cac04189537f888e3b9338b70d3d5b Mon Sep 17 00:00:00 2001 From: Peter Buschenreiter Date: Thu, 18 Jan 2024 15:39:34 +0100 Subject: [PATCH 1/5] disabled speed insights on dev --- src/routes/+layout.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/routes/+layout.ts b/src/routes/+layout.ts index dab78e4..a7e3093 100644 --- a/src/routes/+layout.ts +++ b/src/routes/+layout.ts @@ -2,5 +2,5 @@ import { dev } from '$app/environment'; import { inject } from '@vercel/analytics'; import { injectSpeedInsights } from '@vercel/speed-insights/sveltekit'; -injectSpeedInsights(); +dev || injectSpeedInsights(); inject({ mode: dev ? 'development' : 'production' }); From bcc14fafd42c888e38c4e3de3d3d92f4b0fc0cb2 Mon Sep 17 00:00:00 2001 From: Peter Buschenreiter Date: Thu, 18 Jan 2024 15:40:57 +0100 Subject: [PATCH 2/5] rounded images in dialog --- src/routes/+page.svelte | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/routes/+page.svelte b/src/routes/+page.svelte index 5bbe344..f2a7278 100644 --- a/src/routes/+page.svelte +++ b/src/routes/+page.svelte @@ -31,7 +31,10 @@ ], [ { src: Climbing2, alt: 'Checking out a climbing route while preparing for it' }, - { src: Expo3, alt: 'Seif, Filip and I listening to a live "silent" podcast at Future Entrepreneurship 2022' }, + { + src: Expo3, + alt: 'Seif, Filip and I listening to a live "silent" podcast at Future Entrepreneurship 2022' + }, { src: Subway, alt: 'Posing in front of the subway in Vienna' } ], [ @@ -78,7 +81,8 @@ - +

{image.alt} From e979188ead71a172650b8b603524806f743981ef Mon Sep 17 00:00:00 2001 From: Peter Buschenreiter Date: Thu, 18 Jan 2024 15:41:05 +0100 Subject: [PATCH 3/5] enabled ISR --- src/routes/+layout.server.ts | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/routes/+layout.server.ts b/src/routes/+layout.server.ts index 75c5aae..7ac81a2 100644 --- a/src/routes/+layout.server.ts +++ b/src/routes/+layout.server.ts @@ -1,7 +1,22 @@ +import { BYPASS_TOKEN } from '$env/static/private'; import { supabase } from '$lib/supabase'; import { error } from '@sveltejs/kit'; import type { LayoutServerLoad } from './$types'; +export const config = { + isr: { + // Expiration time (in seconds) before the cached asset will be re-generated by invoking the Serverless Function. + // Setting the value to `false` means it will never expire. + expiration: 60 * 60, + + // Random token that can be provided in the URL to bypass the cached version of the asset, by requesting the asset + // with a __prerender_bypass= cookie. + // + // Making a `GET` or `HEAD` request with `x-prerender-revalidate: ` will force the asset to be re-validated. + bypassToken: BYPASS_TOKEN + } +}; + export const load: LayoutServerLoad = async () => { const { data, error: e } = await supabase .from('testimonials') From c7e20dd2896e48960ff39676e46a8b6a0b7c1f08 Mon Sep 17 00:00:00 2001 From: Peter Buschenreiter Date: Thu, 18 Jan 2024 16:03:12 +0100 Subject: [PATCH 4/5] renamed css file --- src/{app.postcss => app.pcss} | 0 src/routes/+layout.svelte | 2 +- 2 files changed, 1 insertion(+), 1 deletion(-) rename src/{app.postcss => app.pcss} (100%) diff --git a/src/app.postcss b/src/app.pcss similarity index 100% rename from src/app.postcss rename to src/app.pcss diff --git a/src/routes/+layout.svelte b/src/routes/+layout.svelte index 4085c2a..1f91ec4 100644 --- a/src/routes/+layout.svelte +++ b/src/routes/+layout.svelte @@ -1,5 +1,5 @@