1.0.9 • Published 8 days ago
@alwatr/exit-hook v1.0.9
Exit Hook
A utility for registering exit handlers in Node.js.
Installation
yarn add @alwatr/exit-hook
Usage
import {exitHook} from '@alwatr/exit-hook';
const saveAllData = () => {
// save all data
};
exitHook(saveAllData);