TIL

How to trace error in Javascript

console.error(new Error("My error").stack)

Error is a predefined class in JS to track every info about an error