Skip to content
velt/dev exports

velt/dev

API reference

What a program run by velt dev (hot reload) takes part in: the graceful stop before its next version starts. A server joins it so that no request in flight is cut off. For a walkthrough, read the guide.

import { joinStop, drained } from "velt/dev";

Exports

function

drained

#std/dev/stop.vlt:22

Re-exported from velt/dev/stop

function drained()

What joined the graceful stop (joinStop) finished.

function

joinStop

#std/dev/stop.vlt:16

Re-exported from velt/dev/stop

function joinStop(): AbortSignal | null

Joins the graceful stop of velt dev: a signal aborted once the program is asked to stop for its next version, after which the caller stops taking work, finishes what it has and calls drained(); the program exits once everything that joined did. Null outside velt dev, where nothing waits.