Welcome to FastStrap
Modern Bootstrap 5 components for FastHTML.
Build beautiful web UIs in pure Python with zero JavaScript knowledge.
The Vision
FastStrap aims to be the standard component library for FastHTML, providing 100+ production-ready Bootstrap 5 components. It combines the power of Python, the simplicity of FastHTML, and the maturity of Bootstrap into a single, cohesive experience.
Why FastStrap
FastHTML is amazing for building web apps in pure Python, but building UI from scratch can be time-consuming. FastStrap bridges the gap by providing a comprehensive set of production-ready Bootstrap 5 components that just work.
-
Pure Python
No JavaScript, HTML, or CSS knowledge required. Define your UI with Python classes and intuitive keyword arguments.
-
FastHTML Native
Built specifically for FastHTML. Seamlessly integrates with HTMX for dynamic, SPA-like experiences without the complexity.
-
Bootstrap 5.3
Leverages the world's most popular CSS framework. Responsive, accessible, and themeable out of the box.
-
Type Safe
Modern Python 3.10+ type hints for specific arguments. Great IDE support with auto-completion.
{ .grid .cards }
At a Glance
Welcome Back
Features
- 110+ exports: Components and helpers across forms, display, navigation, and layouts.
- HTMX Presets: ActiveSearch, InfiniteScroll, AutoRefresh, LazyLoad, LoadingButton, OptimisticAction, LocationAction, SSEStream.
- SEO Module: SEO meta tags, Open Graph, Twitter Cards, and JSON-LD structured data.
- PWA Module: one-call installable app setup (manifest, service worker, install flow).
- Zero Build Step: No webpack, no npm, no node_modules.
- Dark Mode: Automatic or user-toggled dark mode support.
- HTMX Ready:
hx_*attributes are first-class citizens. - Icons Included: Built-in helper for Bootstrap Icons.
- Visual Effects: Scroll-reveal animations, hover effects, and transitions CSS only.
- Data UI: DataTable, Chart, MetricCard, TrendCard, KPICard, DashboardGrid.
- Renderers: Markdown, SVG, Mermaid.
Stats
- 110+ exports implemented.
- 679+ tests passing.
- 7 interaction presets + 6 response helpers + 1 auth decorator + SSEStream.
- 100% Python.
Future Releases
- Layout primitives: Stack, Cluster, Center, Switcher, Sidebar
- Data tooling: DataFrameViewer (virtualized), DataProfiler, ModelReport layout
- Chart presets: common analysis plots + insight helpers
- Form extensions: FormWizard, Stepper, error summary patterns
- UI extensions: Timeline, ProfileDropdown, SearchBar
- Icon packs: optional icon registries beyond Bootstrap Icons
- Notebook helpers: render-to-HTML convenience for notebooks
License
FastStrap is licensed under the MIT License.