Type Alias: LifecycleUndo
LifecycleUndo = (
signal) =>unknown
Defined in: src/utils/lifecycle.ts:85
The function a lifecycle hook may return: it undoes the hook when the app stops. It receives the signal passed to running.stop(), aborted when stopping takes too long.
Parameters
signal
Returns
unknown
Example
ts
const close: LifecycleUndo = (signal) => server.close({ force: signal.aborted });