Sample CLI
gway vbox render-error
References
Full Code
def render_error(title: str, message: str, *, back_link: bool = True, target: str="uploads") -> str:
"""Helper for error display with optional link back to upload main page."""
html = f"<h1>{title}</h1><p>{message}</p>"
if back_link:
url = gw.web.app.build_url(target)
html += f'<p class="error"><a href="{url}?">Back to {target} page</a></p>'
return html