From 9777fc0322c920cf245df41fee615ce855e8e73b Mon Sep 17 00:00:00 2001 From: Stephen Zhou <38493346+hyoban@users.noreply.github.com> Date: Mon, 16 Mar 2026 18:29:56 +0800 Subject: [PATCH] fix: add csp config for esm.sh --- web/proxy.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/proxy.ts b/web/proxy.ts index 6f2373f1a0..2baa122a30 100644 --- a/web/proxy.ts +++ b/web/proxy.ts @@ -3,7 +3,7 @@ import { Buffer } from 'node:buffer' import { NextResponse } from 'next/server' import { env } from '@/env' -const NECESSARY_DOMAIN = '*.sentry.io http://localhost:* http://127.0.0.1:* https://analytics.google.com googletagmanager.com *.googletagmanager.com https://www.google-analytics.com https://api.github.com https://api2.amplitude.com *.amplitude.com' +const NECESSARY_DOMAIN = 'https://esm.sh *.sentry.io http://localhost:* http://127.0.0.1:* https://analytics.google.com googletagmanager.com *.googletagmanager.com https://www.google-analytics.com https://api.github.com https://api2.amplitude.com *.amplitude.com' const wrapResponseWithXFrameOptions = (response: NextResponse, pathname: string) => { // prevent clickjacking: https://owasp.org/www-community/attacks/Clickjacking