Replies: 1 comment 11 replies
-
You can add a rewrite/redirect for module.exports = {
rewrites() {
return [
{
source: '/:path*.map',
destination: '/404'
}
]
}
} |
Beta Was this translation helpful? Give feedback.
11 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Describe the feature you'd like to request
A simpler way to have sourcemaps in error tracking systems without exposing sourcemaps publicly
Describe the solution you'd like
Generate source maps but disable serving them from deployments, and a more robust / easier way to make artifacts correlate with stackframe filenames
Describe alternatives you've considered
Currently I'm using this kind of hack/solution
in next.config.js
stripPrefix and urlPrefix are important here
_app.js
Rewriting the stack-frame filenames is important here
And a npm script:
This script needs to run twice after
next build
for some reason I haven't identified/isolated yet, otherwise sourcemaps are served publicly from vercel.Beta Was this translation helpful? Give feedback.
All reactions