Skip to content

    Browse components

    Twine

    A bundle of thin glowing threads twisting like strings in the wind, bending toward the cursor.

    Twine

    Open
    Customize

    Installation

    npx shadcn@latest add @glint-ui/twine

    First time using @glint-ui? Add the registry to components.json once, or install by URL: npx shadcn@latest add https://glintui.vercel.app/r/twine.json

    Usage

    import { Twine } from "@/components/ui/twine";
    
    <div className="relative h-96">
      <Twine count={32} color="#22d3ee" accentColor="#c084fc" />
    </div>

    Props

    PropTypeDefaultDescription
    countnumber32Number of threads.
    colorstring"#22d3ee"Color of the first thread.
    accentColorstring"#c084fc"Color of the last thread.
    amplitudenumber1Wave height multiplier.
    speednumber1Wind speed multiplier.
    attractionnumber1Pull toward the cursor.
    thicknessnumber1Stroke width in px.
    classNamestring—Extra classes for the root element.