Rendyn

Component library

189 components

Interaction

Animated Grid Pattern

Animated Grid Pattern exposes cell dimensions, square count and timing controls.

Interactive exampleReact Tailwind CSS

Practical React example

Use a small number of animated squares as a decorative background.

Before you copy and paste

Match the imported component’s client or server rendering boundary before using the example. Copy components/magicui/animated-grid-pattern.tsx and its returned support files from the Code tab; preserve the project-relative paths.

Listed package dependencies: motion.

Use the Code tab for the component files and installation instructions, then adapt the imports in this example to your project.

Use a small number of animated squares as a decorative background

// Usage adapted from Magic UI's pinned MIT source.
// Copyright (c) Magic UI. See ./LICENSES.md.
'use client';

import { AnimatedGridPattern } from "@/components/magicui/animated-grid-pattern"

export function ComponentExample() {
  return (
    <AnimatedGridPattern />
  );
}

Usage example adapted from Magic UI's pinned MIT source. Retain the source licence notices when copying.

Define the containing region and start with a restrained numSquares and maxOpacity. Keep foreground content above the SVG layer.

Customization

AnimatedGridPatternProps.width
Optional; number.
AnimatedGridPatternProps.height
Optional; number.
AnimatedGridPatternProps.x
Optional; number.
AnimatedGridPatternProps.y
Optional; number.
AnimatedGridPatternProps.strokeDasharray
Optional; number.
AnimatedGridPatternProps.numSquares
Optional; number.
AnimatedGridPatternProps.maxOpacity
Optional; number.
AnimatedGridPatternProps.duration
Optional; number.
AnimatedGridPatternProps.repeatDelay
Optional; number.

Integration notes

  • Randomized visual positions should not be used as meaningful data points.
  • Test hydration, reduced motion and responsiveness when the parent’s dimensions change.

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.

Better with your agent

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.

Connect to MCP