template rendering: add feature
template rendering: add feature: a task in smol-software-harbor (Harbor dataset). Add a default filter with an argument to render() in templating.py : {{ nickname default:"friend" }} renders the context value when the key exists and is not empty, otherwise the quoted text ( friend ). Other filters…
The task
Add a `default` filter with an argument to `render()` in `templating.py`: `{{ nickname|default:"friend" }}` renders the context value when the key exists and is not empty, otherwise the quoted text (`friend`). Other filters keep working, and a missing key without `default` still raises `KeyError`. Run `python3 -m…
Part of efederici/smol-software-harbor.