From bef3da2a567e3804e12355d9c3d5c09439dbe2ea Mon Sep 17 00:00:00 2001 From: Joel Klinghed Date: Thu, 17 Jul 2025 23:42:55 +0200 Subject: Humble beginnings Redirect to login if not logged in, on login session cookie is set and projects or reviews are listed. --- client/svelte.config.js | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) (limited to 'client/svelte.config.js') diff --git a/client/svelte.config.js b/client/svelte.config.js index c138f77..cedc080 100644 --- a/client/svelte.config.js +++ b/client/svelte.config.js @@ -3,13 +3,23 @@ import { vitePreprocess } from '@sveltejs/vite-plugin-svelte'; /** @type {import('@sveltejs/kit').Config} */ const config = { - // Consult https://svelte.dev/docs/kit/integrations - // for more information about preprocessors - preprocess: vitePreprocess(), + // Consult https://svelte.dev/docs/kit/integrations + // for more information about preprocessors + preprocess: vitePreprocess(), - kit: { - adapter: adapter() + kit: { + adapter: adapter() + }, + csp: { + directives: { + 'script-src': ['self'] + }, + // must be specified with either the `report-uri` or `report-to` directives, or both + reportOnly: { + 'script-src': ['self'], + 'report-uri': ['/'] } + } }; export default config; -- cgit v1.2.3-70-g09d2