3

I deployed an Angular app with production build. When an error occurs I log it so can I check that the next day. The log shows the error stack in the minified production build:

/main.*****.js:1:7466

As I have no chance to reproduce it in the browser so I cannot use the sourcemaps in the browser. I want to write a script where I can paste this error stack and it finds out where it occurs in the code.

Is this possible and yes, which is the correct approach?

1 Answer 1

1

I'm in the same situation and I stumbled upon this npm package: https://www.npmjs.com/package/sourcemapped-stacktrace

I wasn't able to try it out yet but it does seem very fitting.

Sign up to request clarification or add additional context in comments.

1 Comment

Your answer could be improved by providing an example of the solution and how it helps the OP.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.