Core Library0.xAPI Reference

Choose documentation 3

latest

Current version

latest
English

Early release libtmux is released, and its APIs may still change between releases. This site's structure and URLs may change too.

property libtmux-ts latest

ServerOptions.onInvocation

Called once per tmux invocation, after it answers or fails.

Source and package
Qualified name
ServerOptions.onInvocation
Module
server
Declared in
ServerOptions
Package
libtmux
Source
packages/libtmux/src/server.ts

Description#

The seam for logs, traces and metrics. Every command this server runs reports here, a custom engine's included, and an observer cannot change what a command does — see TmuxInvocationObserver.

Examples#

const traced = new Server({
onInvocation: (report) => {
console.log(report.commands[0]?.[0], report.durationMs, report.delivery);
},
});
Esc

Type to search.

Reference previewOpen reference