Macros§
- pretty_
via_ display - Generate an implementation of PrettyPrint for a given type by delegating to core::fmt::Display.
- pretty_
via_ to_ string - Generate an implementation of PrettyPrint for a given type by delegating to alloc::string::ToString.
Enums§
Traits§
- Pretty
Print - The PrettyPrint trait is used as a building block for pretty printing data or syntax trees, as commonly seen in tools like Prettier.
Functions§
- concat
- Concatenate two documents, producing a single document representing both.
- const_
text - Same as text, but for static/constant strings
- display
- Display the given value using its core::fmt::Display implementation.
- flatten
- Use the leftmost option of every choice in the given document.
- indent
- Increase the indentation level of the given document by
width. - nl
- Render a line break (i.e. newline) in the output
- pretty_
print_ csv - Pretty-print a list of PrettyPrint values as comma-separated items.
- split
- Create a document by splitting
inputon line breaks so ensure the invariants of text are upheld. - text
- Display the given string exactly.