Production-ready components built for the GOTH stack — Go, Templ, HTMX, Tailwind CSS, and Alpine.js. No React. No JSON APIs. Just clean, typed, copy-paste UI.
A form input field. Something every Go dev writes on every project. Here is what it looks like with and without kraft-ui.
<div class="flex flex-col gap-1.5">
<label class="text-sm font-medium
text-text-primary">
Email
</label>
<input
type="email"
placeholder="you@example.com"
class="rounded-md border border-error-500
px-3 py-2 text-sm bg-surface
text-text-primary
placeholder:text-text-muted
focus:outline-none focus:ring-2
focus:ring-error-500
transition-colors"
/>
<p class="text-xs text-error-600">
Invalid email address
</p>
</div>@input.Input(input.Props{
Type: "email",
Label: "Email",
Error: "Invalid email address",
})
// Typed. Consistent. IDE autocomplete.
// One place to update when design changes.
// Every dev on your team writes it
// the same way.75%
less markup per field
1
file to update when design changes
0
class string debates on your team
Set data-theme on your HTML element. Every component adapts instantly. No extra code, no per-theme classes.
<html data-theme={ user.PreferredTheme }>
<!-- every daisyui.* component adapts automatically -->Everything you'd expect from a modern component library, engineered for Go devs who mean business.
Every component takes a Go struct — no magic strings, no map[string]any. Your IDE autocompletes everything.
Pass any hx-* attribute via templ.Attributes. Components are designed for server-driven interactions.
Copy components directly into your project for full ownership, OR import as a Go module dependency.
Dropdowns, modals, tabs — client-only interactions use Alpine.js. No server round-trip needed.
Full design token system via CSS @theme variables. Change your brand color in one line.
ARIA roles, labels, focus management, and keyboard navigation built into every component.
Add to your Go project
go get github.com/appkrafterrz/kraft-ui@latestImport a component
import "github.com/appkrafterrz/kraft-ui/pkg/ui/button"Kraft something
@button.Button(button.Props{Variant: button.VariantPrimary}) {
Kraft it
}