Skip to content

Commit

Permalink
changed source maps generation
Browse files Browse the repository at this point in the history
  • Loading branch information
norbertschuler committed Dec 15, 2021
1 parent 4dadc17 commit 3ab2f01
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 17 deletions.
8 changes: 4 additions & 4 deletions next.config.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
const withPlugins = require("next-compose-plugins");
// Use the hidden-source-map option when you don't want the source maps to be
// publicly available on the servers, only to the error reporting
const withSourceMaps = require("@zeit/next-source-maps")();
const withBundleAnalyzer = require("@next/bundle-analyzer")({
enabled: process.env.ANALYZE === "true",
});
Expand All @@ -16,13 +13,15 @@ const {
SENTRY_PROJECT,
SENTRY_AUTH_TOKEN,
NODE_ENV,
VERCEL_GIT_COMMIT_SHA,
VERCEL_GITHUB_COMMIT_SHA,
VERCEL_GITLAB_COMMIT_SHA,
VERCEL_BITBUCKET_COMMIT_SHA,
SOURCE_VERSION,
} = process.env;

const COMMIT_SHA =
VERCEL_GIT_COMMIT_SHA ||
VERCEL_GITHUB_COMMIT_SHA ||
VERCEL_GITLAB_COMMIT_SHA ||
VERCEL_BITBUCKET_COMMIT_SHA ||
Expand All @@ -46,7 +45,8 @@ if (process.env.NEXT_PUBLIC_VERCEL_ENV === "preview") {
const hasAssetPrefix =
process.env.ASSET_PREFIX !== "" && process.env.ASSET_PREFIX !== undefined;

module.exports = withPlugins([[withBundleAnalyzer], [withSourceMaps]], {
module.exports = withPlugins([[withBundleAnalyzer]], {
productionBrowserSourceMaps: true,
serverRuntimeConfig: {
rootDir: __dirname,
},
Expand Down
12 changes: 0 additions & 12 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
"@sentry/webpack-plugin": "^1.14.2",
"@stripe/react-stripe-js": "^1.4.0",
"@stripe/stripe-js": "^1.13.2",
"@zeit/next-source-maps": "0.0.4-canary.1",
"axios": "^0.21.1",
"dom-to-image": "^2.6.0",
"geocoder-arcgis": "^2.0.5",
Expand Down

0 comments on commit 3ab2f01

Please sign in to comment.