litestar.ChameleonTemplate
A page template as Litestar’s TemplateProtocol: render(**context) renders it with
Usage
litestar.ChameleonTemplate()the engine’s template callables bound to the context.
Methods
| Name | Description |
|---|---|
| render() |
The page, rendered with kwargs as the context (Litestar passes no positional
|
| render_async() | render as a coroutine: the template’s render_async (awaitable values are |
render()
The page, rendered with kwargs as the context (Litestar passes no positional
Usage
render(*args, **kwargs)arguments).
render_async()
render as a coroutine: the template’s render_async (awaitable values are
Usage
render_async(**kwargs)awaited where the template uses them). Litestar’s Template response never calls it; it is for code rendering a template itself.