About
Mouse-Following Line Field Animation A dynamic grid of lines that react and rotate smoothly toward cursor movement, creating an engaging motion effect. Perfect for interactive backgrounds, modern websites, or eye-catching hero sections.
Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Mouse Following Line to your project and fits it to your theme.
Code
How Mouse Following Line is used: the demo's code. The component's own source comes with a free account.
Usage.tsx
import { GridAnimation } from "@/components/ui/mouse-following-line";
const settings = {
strokeLength: 10,
strokeWidth: 1,
spacing: 30,
cols: 40,
rows: 40,
};
export default function Demo(props: Partial<typeof settings>) {
const s = { ...settings, ...props };
return (
<div className="h-screen w-screen flex items-center justify-center overflow-hidden">
<GridAnimation {...s} />
</div>
);
}







