Rainbow Button
Rainbow Button supports native button attributes and optional child composition.
Practical React example
Style one call to action with a distinctive border while preserving normal button or link behavior.
Before you copy and paste
Match the imported component’s client or server rendering boundary before using the example. Copy components/magicui/rainbow-button.tsx and its returned support files from the Code tab; preserve the project-relative paths. Include the returned styles: components/magicui/rainbow-button.css.
Use the Code tab for the component files and installation instructions, then adapt the imports in this example to your project.
Style one call to action with a distinctive border while preserving normal button or link behavior
// Usage adapted from Magic UI's pinned MIT source.
// Copyright (c) Magic UI. See ./LICENSES.md.
'use client';
import { RainbowButton } from "@/components/magicui/rainbow-button"
export function ComponentExample() {
return (
<RainbowButton>Rainbow Button</RainbowButton>
);
}
Usage example adapted from Magic UI's pinned MIT source. Retain the source licence notices when copying.
Use asChild only with a child that supplies the intended semantics, such as a real navigation link. Include the returned CSS for the animated border.
Customization
- RainbowButtonProps.asChild
- Optional; boolean.
Integration notes
- Avoid nesting a button inside a button or using a link for a form submission.
- Keep contrast and visible focus clear in light and dark themes.
Component source: Magic UI documentation . These examples describe the version imported into Rendyn. Upstream APIs may have changed; retain the source licence notices when adapting the code.
Give your agent taste.
The best way to use Rendyn is through MCP. Let your agent find the right component, compare previews and bring the source into your project.
All components are free. Sign up only to connect MCP.