A collection of basic shapes for @pixi/react
Go to website
directory for a working example
Install the package using any package manager you like.
pnpm install pixi-react-shapes
Import the shapes you want to use and pass the draw props to the shape.
import { Circle, Rectangle, RoundedRectangle } from 'pixi-react-shapes';
<>
<Circle drawCircle={[0, 0, 50]} />
<Rectangle drawRect={[-50, -50, 100, 100]} />
<RoundedRectangle draw={[-50, -50, 100, 100, 10]} />
</>