Velahome

Vela

Tailwind-style className compilation for roblox-ts UI — React or Vide.

vela-rbxts · v0.15.0 · pre-1.0

Vela lets you write Tailwind-style classes on roblox-ts UI. At build time it turns them into plain Roblox properties. p-4 becomes a UIPadding child, rounded-lg a UICorner, and bg-slate-700 a BackgroundColor3.

It works with React by default, and with Vide when your tsconfig.json compiles Vide JSX.

Compiled by the real Vela compiler and rendered live. The Classes tab is the source as written; the Lowered tab is what rbxtsc emits.

The Classes tab shows the component as you write it. The Lowered tab shows what ships: Roblox properties and a few helper instances, with no trace of Vela. Every preview in these docs comes from the real compiler.

What you get

A plain string of classes compiles away completely. Only two things add runtime work: a className the compiler can’t read, and variants like hover: that depend on the player’s device.

A class Vela can’t compile is reported, not dropped quietly. tracking-wide warns that Roblox has no letter spacing. A typo in a theme key names the scale it searched. See the diagnostics reference for every code.

The language server uses the same compiler as the build, so completions, hover and errors match what the build does. See editor setup.

Vela covers what maps onto Roblox: colors, gradients, strokes, corners, padding, gap, sizing, position, flex layout and typography. Anything else is rejected with a warning rather than approximated. See scope and status.

Get started

Read these in order:

  1. Installation: install Vela and confirm it works.
  2. Your first component: build a panel and see what each class compiles to.
  3. How it works: the build pipeline, and the two ways a className can compile.
  4. Scope and status: what’s left out, and the gaps that don’t warn.

To skip setup, try the playground. It runs the real compiler in your browser.

Next

className in, Roblox props out.
<frame className="flex flex-col gap-4 p-4 w-80 rounded-lg bg-slate-800 border border-slate-700">
<textlabel className="text-lg font-semibold text-slate-50" Text="Party" />
<textbutton className="h-10 rounded-md bg-blue-600 text-white" Text="Invite" />
</frame>
Compiled, not interpreted
Static classes lower to Roblox props and helper instances during the roblox-ts build. No runtime cost, no generated folder.
Roblox-shaped, not Tailwind-shaped
Utilities map onto UIPadding, UIListLayout, UICorner, UIStroke, and the rest — the instances Roblox actually gives you.
Loud about its gaps
Unsupported families and unknown theme keys emit diagnostics instead of silently doing nothing.

Guides

Learn what lowers, and what doesn't.

Reference

Every class, value, and code.

Pre-1.0, and narrow on purpose.

Packages version in lockstep. Whole Tailwind families are not implemented, a dynamic className resolves against a much smaller utility set than a static one, and per-element restrictions are enforced by the editor rather than the compiler. Read the scope before you depend on a class.

Scope and status →