A simple and customizable SVG grid pattern that can be used as a background element with optional filled squares.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/Max-Samson/magicui/llms.txt
Use this file to discover all available pages before exploring further.
Installation
Usage
With Filled Squares
Dashed Stroke
Props
| Prop | Type | Default | Description |
|---|---|---|---|
width | number | 40 | Width of each grid cell |
height | number | 40 | Height of each grid cell |
x | number | -1 | X offset of the pattern |
y | number | -1 | Y offset of the pattern |
squares | Array<[number, number]> | - | Array of [x, y] coordinates for filled squares |
strokeDasharray | string | "0" | Stroke dash array for the grid lines |
className | string | - | Additional CSS classes for the SVG element |