boid-flock
v1.4.2
Published
A React component to render boids as a background
Downloads
19
Maintainers
Readme
Boid Flock
A React component to render a boids simulation anywhere
Installation
npm add 'boid-flock'
Usage
import { BoidFlock } from "boid-flock";
export function YourComponent() {
return (
<BoidFlock>
<span>You can render whatever you like in here</span>
</BoidFlock>
);
}
Optionally you can pass a boidCount
prop to the component to control the number of boids rendered.
import { BoidFlock } from "boid-flock";
export function YourComponent() {
return (
<BoidFlock boidCount={3}>
<p>There's only 3 boids in my background</p>
</BoidFlock>
);
}