Ali Imam

Starfield

Heroes 407

About

The component retains the core functionality of the starfield animation, including props for customization, and uses React with a canvas element for rendering.

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Starfield to your project and fits it to your theme.

Code

How Starfield is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

import { Starfield } from "@/components/ui/starfield-1";

export default function DemoOne() {
  return (
    <div className="relative flex h-screen w-full flex-col items-center justify-center overflow-hidden">
      <Starfield/>
      <span className="pointer-events-none z-10 text-center text-7xl leading-none font-semibold tracking-tighter whitespace-pre-wrap text-white">
        Starfield
      </span>
    </div>
  )
}

Dependencies

More by Ali Imam

View all
  • Liquid Glass Button

    Liquid Glass Button

    7.3K
  • Shader Animation

    Shader Animation

    3.9K
  • WebGL Shader

    WebGL Shader

    2.8K
  • Shiny Button

    Shiny Button

    2.5K
  • Shader Lines

    Shader Lines

    2.5K
  • GLSL Hills

    GLSL Hills

    2.2K
  • Canvas

    Canvas

    1.8K
  • Gallery

    Gallery

    1.6K

More in Heroes

View all
  • Agency Hero Section

    Agency Hero Section

    1.1K
  • Real Estate 3D Hero

    Real Estate 3D Hero

    89
  • Responsive Hero Banner

    Responsive Hero Banner

    2.2K
  • SaaS Template

    SaaS Template

    2.8K
  • AI SaaS Workflow Hero

    AI SaaS Workflow Hero

    37
  • App Integration Celestial Hero

    App Integration Celestial Hero

    17
  • Chroma Sense Hero

    Chroma Sense Hero

    23
  • Hero

    Hero

    1.4K