Back to blog
Quick tips for using shadcn/ui
This is a quick post.
Quick posts are... well quickly drafted.
- Avoid referring to colours directly. Create
bg-successinstead ofbg-green-500. - Use CSS variables for design tokens. Create
--color-successinstead of#22c55e. - Use shadcn/ui's semantic classnames. Prefer
bg-primaryoverbg-gray-500. - Don't override the 'ui' folder. Create wrapper components instead.