From b243d2a5234ce876ed25f867d02547512ea34540 Mon Sep 17 00:00:00 2001 From: LPM Date: Mon, 6 Oct 2025 10:53:40 -0400 Subject: [PATCH 1/5] added CSP and prerender config set warning --- sveltekit/svelte.config.js | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/sveltekit/svelte.config.js b/sveltekit/svelte.config.js index ad0e153..c898311 100644 --- a/sveltekit/svelte.config.js +++ b/sveltekit/svelte.config.js @@ -7,7 +7,28 @@ const config = { // Consult https://svelte.dev/docs/kit/integrations // for more information about preprocessors preprocess: [vitePreprocess(), mdsvex()], - kit: { adapter: adapter() }, + kit: { + adapter: adapter(), + prerender: { + handleHttpError: 'warn' + }, + csp: { + mode: 'auto', + directives: { + 'default-src': [ "'self'", "https://codefallacy.com", "https://www.codefallacy.com" ], + 'frame-src': [ "'self'", "https://codefallacy.com", "https://www.codefallacy.com" ], + 'connect-src': [ "'self'", "https://codefallacy.com", "https://www.codefallacy.com" ], + 'script-src': [ "'self'", "https://codefallacy.com", "https://www.codefallacy.com" ], + 'script-src-elem': [ "'self'", "https://codefallacy.com", "https://www.codefallacy.com" ], + 'style-src': [ "'self'", "'unsafe-inline'", "https://codefallacy.com", "https://www.codefallacy.com" ], + 'img-src': [ "'self'", "data:", "https://codefallacy.com", "https://www.codefallacy.com" ], + 'font-src': [ "'self'", "https://codefallacy.com", "https://www.codefallacy.com" ], + "base-uri": [ "'self'", "https://codefallacy.com", "https://www.codefallacy.com" ], + "form-action": [ "'self'", "https://codefallacy.com", "https://www.codefallacy.com" ], + "object-src": ["'self'", "https://codefallacy.com", "https://www.codefallacy.com" ] + } + } + }, extensions: ['.svelte', '.svx'] }; From 2532e454b813151322641bc3bee39c4f6936662a Mon Sep 17 00:00:00 2001 From: LPM Date: Mon, 6 Oct 2025 10:59:28 -0400 Subject: [PATCH 2/5] added head tag to landing page --- sveltekit/src/routes/+page.svelte | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/sveltekit/src/routes/+page.svelte b/sveltekit/src/routes/+page.svelte index f76aff1..c32e892 100644 --- a/sveltekit/src/routes/+page.svelte +++ b/sveltekit/src/routes/+page.svelte @@ -4,6 +4,11 @@ import svg from '$lib/assets/codefallacy/youtube.svg'; + + CodeFallacy + + +
codefallacy From a0cc647fe6bd656cec7b2235c8eb85560f4028c2 Mon Sep 17 00:00:00 2001 From: LPM Date: Mon, 6 Oct 2025 11:06:54 -0400 Subject: [PATCH 3/5] added metadata description and added additional breakpoint --- sveltekit/src/routes/+page.svelte | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/sveltekit/src/routes/+page.svelte b/sveltekit/src/routes/+page.svelte index c32e892..4593eb2 100644 --- a/sveltekit/src/routes/+page.svelte +++ b/sveltekit/src/routes/+page.svelte @@ -6,20 +6,21 @@ CodeFallacy - + +