Neon Border

A visually appealing neon border component with customizable animations and colors.

API

Prop NameTypeDefaultDescription
color1string"#0496ff"Primary color of the neon border.
color2string"#ff0a54"Secondary color of the neon border.
animationType"none" | "half" | "full""half"Type of animation effect applied to the border.
durationnumber6Duration of the animation effect in seconds.
classstring""Additional CSS classes for styling.

Install using CLI

npm
pnpm
bun
yarn
npx shadcn-vue@latest add "https://inspira-ui.com/r/neon-border.json"

Install Manually

Copy and paste the following code in the same folder

NeonBorder.vue

Features

  • Customizable Colors: Allows setting primary and secondary neon colors.
  • Three Animation Modes: Supports none, half, and full animation effects.
  • Adjustable Animation Duration: Duration can be fine-tuned for different effects.
  • Reactive Design: Uses Vue’s reactivity system for dynamic updates.
  • Scoped Styles: Ensures styles do not interfere with other components.

Credits

  • Inspired by modern neon border effects.