Documentation
¶
Overview ¶
Package json provides JSON syntax highlighting for clog.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Highlight ¶
Highlight applies syntax highlighting to s using the provided styles. By default inter-token whitespace is stripped, flattening pretty-printed JSON to a single line. Set style.JSON.Indent to a non-empty string to pretty-print with indentation instead. Returns s unchanged when styles is nil.
The scanner is defensive: on any unexpected byte the remaining input is emitted unstyled rather than panicking.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.