From 25358a9463fef8b67d96c6dd8be084a8dbdae6ff Mon Sep 17 00:00:00 2001 From: MartinBraquet Date: Fri, 13 Mar 2026 13:04:06 +0100 Subject: [PATCH] Update Sentry project name --- web/next.config.ts | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/web/next.config.ts b/web/next.config.ts index 8c7b9126..88c6e89d 100644 --- a/web/next.config.ts +++ b/web/next.config.ts @@ -85,6 +85,29 @@ const nextConfig: NextConfig = { }, ], }) + if (!dev) { + // Find and disable source maps in CSS plugins + config.plugins.forEach((plugin: any) => { + if (plugin.constructor.name === 'MiniCssExtractPlugin') { + plugin.options = {...plugin.options, ignoreOrder: true} + } + }) + + config.module.rules.forEach((rule: any) => { + if (rule.oneOf) { + rule.oneOf.forEach((r: any) => { + if (r.use) { + const uses = Array.isArray(r.use) ? r.use : [r.use] + uses.forEach((u: any) => { + if (u.loader?.includes('css-loader') && u.options) { + u.options.sourceMap = false + } + }) + } + }) + } + }) + } return config }, async redirects() { @@ -112,7 +135,7 @@ export default withSentryConfig(nextConfig, { org: 'compass-0l', - project: 'javascript-nextjs', + project: 'compass', // Only print logs for uploading source maps in CI silent: !process.env.CI,