Let's say my node.js. application is running If there is an error (I mean ALL errors. Not only a web error. If it goes to Err out, it is counted), how can I call a function to send an email to me?
Basically, before I want him to write err.out, I want an email to be sent to me.
I am using node.js and express.
Edit: I know how to send an email. The question I want to know is how to catch the error . Do you know how out.log log appears on error? Well, right now, I tail -f out.log, watching for errors. I canβt sit at home all day doing this. I want errors to be emailed to me anytime they appear in out.log.
I need all emails sent to me by email. (Not just Express errors). If it is registered, I want this error to be emailed.
TIMEX source share