fasthtml
Installation
SKILL.md
FastHTML
Follow current FastHTML conventions, not FastAPI, Django, or SPA conventions. Keep code small, HTML-first, and signature-driven.
Start Here
- Match the repo's existing style first.
- Default to
from fasthtml.common import *unless the repo already uses explicit imports. - Default to
app, rt = fast_app()and@rthandlers unless the repo already usesFastHTML()or verb-specific decorators. - Prefer
index()for/, function-name routes for the rest, and route function references instead of hard-coded URLs. - Keep route handlers as plain functions with accurate annotations. FastHTML inspects signatures at runtime.
Default Build Pattern
Use this shape unless the local app clearly uses another pattern:
from fasthtml.common import *