libtmux Reference MCP Search
On this page

selection.decodeWhereDocument

View as Markdown

Module
selection
Package
@libtmux/libtmux
Source
packages/libtmux/src/selection.ts
decodeWhereDocument ( input : : unknown ) WhereDocumentV1
function [source]
function [source]
decodeWhereDocument

Validate a WHERE document and restore camelCase criteria names.

The returned document is canonical and deeply frozen.

Examples

import { decodeWhereDocument } from "libtmux/selection";
const document = decodeWhereDocument(
  JSON.parse('{"model":"pane","version":1,"where":{"pane_title":"logs"}}'),
);
if (document.model === "pane") snapshot.panes.where(document.where);
Raises

0 declared, 0 inherited

Esc

Type to search.