Private
Public Access
1
0

Allow dark mode theme script via CSP hash

The inline script in app.html that applies the dark mode class before
paint is not covered by SvelteKit's nonce system. Whitelist it by
its SHA-256 hash instead.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Catherine Renelle
2026-03-09 08:20:22 -04:00
parent f641e65c1f
commit 8f5a931951
+1 -1
View File
@@ -12,7 +12,7 @@ const config = {
csp: {
directives: {
'default-src': ['self'],
'script-src': ['self']
'script-src': ['self', 'sha256-PDIMa2Wg+qyPaCjQ/EcSk+qN0Ftomecz3B0NZzZHivs=']
}
}
}