k8ordo
  • UI
  • Form
  • State
  • Router
  • Static
  • Server
Switch to dark mode
  • Get Started
  • Theming
  • i18n
  • Components
  • Hooks
  • Helpers
  • AI
Open navigation
Styling
  • cn
React
  • mergeRefs
  • mergeProps
  • chain
  • createSafeContext
k8ordo

React libraries that use Baseline features without holding back.

Packages
  • @k8ordo/ui
  • @k8ordo/form
  • @k8ordo/state
  • @k8ordo/router
  • @k8ordo/static
  • @k8ordo/server
UI
  • Get Started
  • Theming
  • i18n
  • Components
  • Hooks
  • Helpers
  • AI Chat
  • Generative UI
  • AI Agents
  • Storybook
Resources
  • GitHub
  • npm

© 2026 k8o — MIT License

Typeset in Noto Sans JP & M PLUS 2

Helpers

Styling
  • cn
React
  • mergeRefs
  • mergeProps
  • chain
  • createSafeContext

cn

A class name utility combining clsx and tailwind-merge.

Import

Usage

Basic Usage

Merged classes
Conditional classes

Parameters

...inputs
Type: ClassValue[]
Default: -
PropTypeDefault
...inputsClassValue[]-

Return Value

className
Type: string
Default: -
PropTypeDefault
classNamestring-
import { cn } from '@k8ordo/ui';
const className = cn(
  'rounded-lg border px-4 py-2',
  'bg-bg-mute text-fg-base',
);

// Conditional classes
const className = cn(
  'rounded-lg px-4 py-2',
  isActive && 'bg-bg-mute',
  isError && 'bg-red-500',
);