death
Gracefully cleanup when termination signals are sent to your process.
catch-exit
Catch Node.js exit conditions, including errors and unhandled rejections.
diehard
Gracefully clean up your program at termination with multiple sync and/or async handlers. Wraps the `death` npm module.