I made a Tailwind alternative for Preact
Details
- External ID
- 46576153
- Source
- HN
- Company
- —
- Product
- I made a Tailwind alternative for Preact
- Website domain
- github.com
- Launched
- Jan. 11, 2026
- Cohort
- —
- Upvotes
- 6
- Upvotes percentile
- 0.2549407114624506
- Tags
- —
- Fetched at
- Sept. 7, 2026, 9:25 p.m.
- Updated at
- Sept. 7, 2026, 9:25 p.m.
Description
This is a small TailwindCSS alternative based on a css template literal. I was inspired by styled-components and EmotionCSS, which however do not work well with ViteJS and specifically Preact.This provides a better experience than Tailwind, as you can use all CSS language features without learning new conventions while maintaining a per-component styling approach.This also turns out to be more inspectable in the browser's dev-tools, as snippets are extracted as-is and are not fragmented across thousands of small classes.I wanted something more optimized than other CSS-in-JS alternatives that generate CSS at runtime, so I created a ViteJS plugin for this. It extracts all style snippets, replaces them with classes like css-a1b2c3, and injects all the corresponding styles into a CSS file in place of an "@extracted-css" directive.There is also a preact options hook that adds a custom "classList" attribute, which maps to clsx for easy class composition (similarly to VueJS, Svelte, etc.).P.S. I know other frameworks exist, but I have really been enjoying using Preact for frontend development lately.
Enrichment
- Theme
- graphic design assets and utilities
- Vertical
- Horizontal
- Function
- Dev tools
- Audience
- Developer
- AI stance
- Not AI
- Project type
- Hobby / open-source project
- Normalized one-liner
- css framework for preact
- Manually corrected
- False
Could you build this?
Yes Building a tagged template literal CSS-in-JS utility for Preact and Vite involves standard runtime style injection or a basic build-time Babel/Vite plugin, easily implemented via vibe coding.
Discussion
No comments on this launch.
Competitors
Other products that read as similar to this one — 147 launches clear the similarity bar, closest 8 shown.
Attention rank: #129 of 148 (itself plus its competitors, highest first — normalized so YC and Product Hunt are compared fairly).
Launched 68 days after the earliest competitor.
- Mlut · hn · 2026-02-25 · 5 upvotes · similarity 0.60
- SVG2CSS · ph · 2026-09-14 · 1 upvotes · similarity 0.51
- htmlwind · ph · 2026-09-24 · 1 upvotes · similarity 0.51
- MiroMiro v2 · ph · 2026-05-11 · 177 upvotes · similarity 0.50
- Orthinal · ph · 2026-09-30 · 1 upvotes · similarity 0.45
- Themeable HN · hn · 2026-04-20 · 8 upvotes · similarity 0.45
- I built a declarative layout engine for SVG, Canvas, WebGL · hn · 2026-07-03 · 5 upvotes · similarity 0.43
- VectorNest responsive web-based SVG editor · hn · 2026-02-18 · 86 upvotes · similarity 0.43
Other launches for this product
- No other launches for this product.
Same idea, different domain
Nobody's really built a dev tools tool for Sales yet.