# `LibTmux.Format`
[🔗](https://github.com/libtmux/libtmux-elixir/blob/b72452c198917433229bdc266a68c163541b6127/lib/libtmux/format.ex#L1)

Constructs literal operands for tmux formats without evaluating their text.

Command quoting and format quoting are separate. A literal may contain
newlines or arbitrary non-NUL bytes; this does not qualify its output for
a shared line-oriented control lane.

# `field`

```elixir
@spec field(String.t()) :: binary()
```

Encodes one named field for `LibTmux.Codec.decode_field/3` with `encoding: :escaped_v1`.

Backslashes are replaced first, then dollars and ASCII control bytes.
This protects values from tmux 3.4's ambiguous print escaping. The `v1:`
prefix and encoded newlines prevent field text from becoming reply guards.
This is one field per response, not a delimiter-framed row or arbitrary
format wrapper. The caller must still bound the response and validate the
field against its schema and the connected server's capabilities.

# `literal`

```elixir
@spec literal(binary()) :: binary()
```

Returns a format expression that expands to exactly the supplied non-NUL bytes.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
