Skip to content

Commit

Permalink
fix: cleanup old CSP header
Browse files Browse the repository at this point in the history
  • Loading branch information
gander committed Nov 26, 2024
1 parent 9b8b4b8 commit 62ec5de
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import {defineConfig} from 'vite';
import vue from '@vitejs/plugin-vue';
import HtmlPlugin, {IHTMLTag, ScriptTag} from 'vite-plugin-html-config';
import HtmlPlugin, {ScriptTag} from 'vite-plugin-html-config';
import {VitePWA} from 'vite-plugin-pwa';

// https://vitejs.dev/config/
Expand All @@ -27,12 +27,6 @@ export default defineConfig(({command}) => {
}
}

const metas: IHTMLTag[] = [{
'http-equiv': 'Content-Security-Policy',
'content': `default-src 'self'; img-src * data: blob:; media-src 'self' data:; script-src 'self' 'unsafe-inline' 'unsafe-eval' https://sentry.gander.tools/ https://browser.sentry-cdn.com/ https://medama.gander.tools/; style-src 'self' 'unsafe-inline'; frame-src 'self'; connect-src 'self' blob: https://sentry.gander.tools/api/ https://medama.gander.tools/api/; font-src 'self'; worker-src 'self' blob:`
}];


const pwaOptions = {
selfDestroying: true,
includeAssets: ['favicon-32x32.png', 'favicon-16x16.png', 'apple-touch-icon.png', 'robots.txt'],
Expand Down Expand Up @@ -78,7 +72,7 @@ export default defineConfig(({command}) => {
},
plugins: [
vue(),
HtmlPlugin({headScripts, metas}),
HtmlPlugin({headScripts}),
VitePWA(pwaOptions),
],
};
Expand Down

0 comments on commit 62ec5de

Please sign in to comment.