- Accordion
- Attachment
- Avatar
- Badge
- Breadcrumb
- Button
- Button Group
- Card
- Checkbox
- Code Block
- Collapsible
- Dialog
- Dropdown Menu
- Empty
- Field
- Hover Card
- Input
- Input Group
- Input OTP
- Item
- Label
- Marker
- Message
- Number Flow
- Pagination
- Popover
- Progress
- Radio Group
- Select
- Slider
- Sonner
- Spinner
- Switch
- Tooltip
- Separator
- Sheet
- Tabs
- Textarea
- Toggle
- Toggle Group
- Trace
Frakment works in any Remix 2+ project with React 19 and Tailwind v4. This guide covers both a new project via the CLI and an existing app.
Prerequisites
- Remix 2 or newer
- React 19
- TypeScript
- Tailwind CSS v4
Components target React 19 and Tailwind v4. For React 18, some components need forwardRef adjustments. For Tailwind v3, port the tokens from Theming manually.
Use the CLI
Scaffold a new Remix app with Frakment installed.
Create project
$ bunx --bun create-remix@latest app cd app$ npx create-remix@latest app cd app$ pnpm create remix@latest app cd app$ yarn create remix@latest app cd app
Install Tailwind v4
$ bun add tailwindcss@latest @tailwindcss/vite$ npm install tailwindcss@latest @tailwindcss/vite$ pnpm add tailwindcss@latest @tailwindcss/vite$ yarn add tailwindcss@latest @tailwindcss/vite
Register the Vite plugin:
import { vitePlugin as remix } from "@remix-run/dev";
import tailwindcss from "@tailwindcss/vite";
import { defineConfig } from "vite";
export default defineConfig({
plugins: [remix(), tailwindcss()],
});Add components
$ bunx --bun frakment@latest init npx frakment@latest add bubble$ npx frakment@latest init npx frakment@latest add bubble$ pnpm dlx frakment@latest init npx frakment@latest add bubble$ yarn dlx frakment@latest init npx frakment@latest add bubble
Use it
import { Bubble, BubbleContent } from "@/components/ui/message";
export default function Index() {
return (
<Bubble>
<BubbleContent>Hello, Frakment.</BubbleContent>
</Bubble>
);
}Existing Project
Add Frakment to a Remix app you already created.
Install Tailwind v4
$ bun add tailwindcss@latest @tailwindcss/vite$ npm install tailwindcss@latest @tailwindcss/vite$ pnpm add tailwindcss@latest @tailwindcss/vite$ yarn add tailwindcss@latest @tailwindcss/vite
Register the Vite plugin:
import { vitePlugin as remix } from "@remix-run/dev";
import tailwindcss from "@tailwindcss/vite";
import { defineConfig } from "vite";
export default defineConfig({
plugins: [remix(), tailwindcss()],
});Run frakment init
$ bunx --bun frakment@latest init$ npx frakment@latest init$ pnpm dlx frakment@latest init$ yarn dlx frakment@latest init
Point to app/tailwind.css when prompted. The CLI injects the theme block after your imports.
Configure the import alias
In tsconfig.json:
{
"compilerOptions": {
"baseUrl": ".",
"paths": {
"@/*": ["./*"]
}
}
}Add a component
$ bunx --bun frakment@latest add bubble$ npx frakment@latest add bubble$ pnpm dlx frakment@latest add bubble$ yarn dlx frakment@latest add bubble
Project structure
Verify
ls app/components/ui/bubble.tsxThen render it in a route. If it renders without errors, you are ready.
Troubleshooting
Make sure @tailwindcss/vite is registered in vite.config.ts and restart the dev server. Vite caches the plugin list in memory.
Check tsconfig.json paths and the aliases in components.json. Both must match.
Next
- Theming - customize tokens and dark mode
- Components - browse the catalog
- Remix docs - framework reference