Skip to main content

parse_ansi

Function parse_ansi 

Source
pub fn parse_ansi(line: &str) -> Vec<Span>
Expand description

Parse a line containing ANSI SGR colour escapes into coloured Spans. Only the foreground-colour subset is handled (others are stripped); enough to make CLI output match the palette.