Skip to main content

keep_lazy_text

A decorator for functions that accept lazy arguments and return text.

def keep_lazy_text(
func: callable
) - > function

A decorator for functions that accept lazy arguments and return text.

Parameters

NameTypeDescription
funccallableThe function to be decorated which typically processes text or lazy string-like objects

Returns

TypeDescription
functionA wrapped version of the input function that ensures lazy objects are handled correctly and the output is cast to a string.