labb 0.5.0 is out

Build beautiful reactive
Django apps.

labb is the reactive UI component library for Django. Server-rendered components, blocks, charts and icons, written as HTML tags in the templates you already have.

Free and open source. MIT licensed.

Built on
Blocks
See all blocks
3/5
Fullstack
/blocks/app/lb/data-table/customers/
Components
76+
Themed and accessible
Icons
1,600+
No SVG copy-pasting required
JS overhead
~0
Reactive on demand

Designed for Django

Your templates stay templates. Your views stay views.

Still a Django template.

No new language, and no build step beyond Tailwind. Your views, your context, your loops.

{% for p in products %} … {% endfor %}

Your views stay views.

Updates hit an ordinary Django view that returns the page. No JSON API, no serializers, no partial endpoints.

return render(request, 'page.html', ctx)

Zero JS by default.

Static pages ship no JavaScript at all. Interactivity loads only on the pages that use it.

static page → 0 kB JavaScript

Named components, not attribute soup.

You write a component with a name and props, not a div carrying six data attributes.

c-lb.button variant='primary'

Themed out of the box.

Components take their colours from the daisyUI theme. Switch the theme, and the whole app follows.

data-theme="corporate"

Free and open source.

Released under the MIT license. Use the components, blocks, charts and icons in any project, commercial or personal.

pip install labbui

Make it yours.

Pick a theme and everything repaints, with no JavaScript. Build your own to match your brand.

Visualise your data

Eight chart types, drawn by Chart.js.
Coloured from your daisyUI palette, driven by data from your view.

1,600+ icons, inline and themed

Icon packs rendered as inline SVG. No sprite sheet, no icon font.

Questions.

What labb is and where it fits in a Django project.

Do I need to know JavaScript?

No. You write Python, HTML-like components, and a few data- attributes when you want interactivity. There is no JavaScript framework to learn and no frontend build to manage. Your interfaces stay in your Django templates.

Does labb ship JavaScript to the browser?

Only on pages that use interactivity. Static pages ship zero JavaScript, so a plain page stays as light as hand-written HTML.

Do I need Node or a build step?

Only the Tailwind CSS build for styling, the same one any daisyUI project uses. There is no JavaScript bundling and no Node application to run. Components render on the server as ordinary Django templates.

How is this different from django-cotton?

labb is built on Cotton. django-cotton is the component engine that lets you write <c-...> tags with props and slots. labb is the component library on top of it: themed, accessible components, plus theming and reactivity. Cotton gives you the mechanism; labb gives you the components.

Do I need to learn Datastar?

No. Datastar is the engine under labb's reactive components. You can reach for it directly if you want finer control, but you do not have to. For most interactivity the components handle it for you.

Why not just HTMX or Alpine?

HTMX and Alpine are low-level primitives: you wire behaviour together with attribute strings on raw HTML. labb gives you named, themed, accessible components instead, so you work with <c-lb.button> and <c-lb.table> rather than assembling class and attribute strings by hand.

Why not React, Vue, or a SPA?

If you are a Django developer who does not want to run a separate frontend stack, labb keeps everything server-rendered in your templates. There is no separate API layer, no client-side router, and no second codebase to keep in sync. You add interactivity where you need it, without adopting a SPA.

Can I add it to an existing Django project?

Yes. Run pip install labbui, add it to INSTALLED_APPS, and drop the dependencies component into your base template. There is no required project structure. It fits into what you already have.

Is it production-ready?

labb is early-stage (0.x) and still evolving. Solid for new projects and prototypes; expect some API churn before 1.0.

Add labb to your project.

Install, then write your first component.

terminal
pip install labbui
labb init --defaults && labb setup

# <c-lb.button variant="primary">Ready.</c-lb.button>