styling

📁 epicenterhq/epicenter 📅 Jan 19, 2026
43
总安装量
19
周安装量
#9009
全站排名
安装命令
npx skills add https://github.com/epicenterhq/epicenter --skill styling

Agent 安装分布

claude-code 15
gemini-cli 13
antigravity 12
opencode 12
codex 11
cursor 9

Skill 文档

Styling Guidelines

Minimize Wrapper Elements

Avoid creating unnecessary wrapper divs. If classes can be applied directly to an existing semantic element with the same outcome, prefer that approach.

Good (Direct Application)

<main class="flex-1 mx-auto max-w-7xl">
	{@render children()}
</main>

Avoid (Unnecessary Wrapper)

<main class="flex-1">
	<div class="mx-auto max-w-7xl">
		{@render children()}
	</div>
</main>

This principle applies to all elements where the styling doesn’t conflict with the element’s semantic purpose or create layout issues.

Tailwind Best Practices

  • Use the cn() utility from $lib/utils for combining classes conditionally
  • Prefer utility classes over custom CSS
  • Use tailwind-variants for component variant systems
  • Follow the background/foreground convention for colors
  • Leverage CSS variables for theme consistency