pretty
Format value for printing to console.
def pretty(
value: str,
width: int = 80,
nl_width: int = 80,
sep: str = '\n',
**kw: Any
) - > str
Format value for printing to console.
Parameters
| Name | Type | Description |
|---|---|---|
| value | str | The object or string to be formatted for display. |
| width | int = 80 | The maximum number of characters per line for standard formatting. |
| nl_width | int = 80 | The maximum line width used specifically when formatting dictionaries or tuples. |
| sep | str = '\n' | The separator character used to prefix formatted dictionaries and tuples. |
| **kw | Any | Additional keyword arguments passed directly to the underlying pformat function. |
Returns
| Type | Description |
|---|---|
str | The formatted string representation of the input value, adjusted for console width and indentation. |