Grid View Spec¶
grid-view-spec describes dashboard pages as a tree of blocks: tables, filters, KPIs, charts,
actions, and layout areas. The Python package grid_view_spec validates specs, renders HTML, and
exposes export hooks. Host applications supply rows and business logic; the spec describes
structure only.
The PyPI distribution is grid-view-spec. The Python package imports as grid_view_spec.
See the live Interactive Demo Showcase to explore working multi-backend dashboards.
What you build¶
from grid_view_spec import GridViewSpec, validate_spec
from grid_view_spec.render import render_grid_view_spec
spec = GridViewSpec(id="orders", blocks=(...), layout=...)
validate_spec(spec)
html = render_grid_view_spec(spec, rows, host=host)
One loader boots the page: {% grid_view_spec_assets part='js' force_core=True %} → GridView.bootScope().
KPI and chart numbers always come from Python rows — never from untrusted spec input.
Documentation map¶
| Group | Start here |
|---|---|
| Install and first page | Getting started |
| Concepts | Architecture overview |
| Spec contract | GridViewSpec |
| Blocks | Block catalog |
| Tables | Tables overview |
| Filtering | Filter semantics |
| Visualization | KPI and charts |
| Integration | Django |
| Export | Page pattern |
| Tools | MCP server |
| Reference | Python types |
Backends¶
| Backend | Use when |
|---|---|
| Django | Templates, GridPreference, export views |
| Jinja2 / Starlette / FastAPI | Headless HTML hosts |
| Wire / MCP | JSON storage, IDE validation |
Optional extras¶
| Extra | Purpose |
|---|---|
[django] |
Django template tags, URL routes, ORM preference model |
[fastapi] / [starlette] |
ASGI page routes & helper middleware |
[mcp] |
gridviewspec-mcp CLI & AI assistant tools |
[pdf] |
WeasyPrint PDF export pipeline |
[xlsx] |
XlsxWriter Excel export pipeline |
[static-charts] |
Matplotlib static chart rendering |
Links¶
- PyPI
- GitHub
- Changelog
- Architecture reference (maintainers)