logblock

command
v0.2.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 2, 2026 License: Apache-2.0 Imports: 3 Imported by: 0

README

LogBlock Example

This example shows framed caller-provided log excerpts with width-aware compaction.

LogBlock example

Run

go run ./examples/logblock --format human --style always
COLUMNS=72 go run ./examples/logblock --format human --style always --content long --max-width 48 --wrap-mode never

Real Library Shape

_ = printer.LogBlock(laslig.LogBlock{
	Title:    "stderr excerpt",
	Body:     "INFO boot complete\nWARN retry scheduled\nERROR dependency missing",
	Footer:   "Explicit caller-provided excerpts only.",
	MaxWidth: 48,
	WrapMode: laslig.TableWrapNever,
})

Log blocks reuse the same TableWrapMode enum as tables, panels, and code blocks. never and truncate currently render the same way on purpose; both avoid wrapping and compact by truncating when needed.

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL