Vibe.Terminal.Snapshot (vibe v0.2.2)

Copy Markdown View Source

Terminal-aware snapshots for ANSI/VT output.

Uses Ghostty when available so cursor movement, carriage returns, wrapping, colors, and Unicode width are interpreted like a real terminal.

Summary

Types

t()

@type t() :: %{
  plain: String.t(),
  html: String.t() | nil,
  vt: String.t() | nil,
  cells: list() | nil,
  truncated?: boolean()
}

Functions

from_ansi(data, opts \\ [])

@spec from_ansi(
  iodata(),
  keyword()
) :: {:ok, t()} | {:error, term()}