Skip to content

Commit

Permalink
Re-enable sourcemap uploading to Sentry in builds (#148)
Browse files Browse the repository at this point in the history
  • Loading branch information
markspolakovs authored Sep 10, 2024
1 parent e3c4d32 commit d5bdcdb
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 2 deletions.
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -48,4 +48,6 @@ next-env.d.ts
# Sentry Auth Token
.sentryclirc

certificates
certificates
# Sentry Config File
.env.sentry-build-plugin
21 changes: 20 additions & 1 deletion next.config.build.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
// This config file contains only the necessary next config needed in production
const { withSentryConfig } = require("@sentry/nextjs");

/** @type {import('next').NextConfig} */
const nextConfig = {
experimental: {
Expand All @@ -24,4 +26,21 @@ const nextConfig = {
},
};

module.exports = nextConfig;
const sentryWebpackPluginOptions = {
org: "ystv",
project: "calendar2023",
};

const sentryOptions = {
// Upload additional client files (increases upload size)
widenClientFileUpload: true,

// Hides source maps from generated client bundles
hideSourceMaps: true,
};

module.exports = withSentryConfig(
nextConfig,
sentryWebpackPluginOptions,
sentryOptions,
);

0 comments on commit d5bdcdb

Please sign in to comment.