Skip to content
Advertisement

How to collect all console outputs or access current content of console in frontend

I am using angular and I would like to implement a bug report function in my app. For that I want to send the content of the browsers console for debugging. But how can I reach out to it.

Not every error is thrown manually with console.log(… so that I could save it at the same time, some errors are thrown from angular itself or thrown Exceptions from httpservice.

Is it possible to access the content of the frontend console?

Thank you.

Advertisement

Answer

It’s a better approach, if you do not rely on the console. It’s up to you, but I say that letting an error reaching the console is not a best practice. You can catch the errors before they arrive on the console anyway.

User contributions licensed under: CC BY-SA
8 People found this is helpful
Advertisement