@simbashrd/the-particles
v1.0.1
Published
Legacy 3D engine and utilities for creative coding.
Readme
@simbashrd/the-particles
Legacy 3D engine and utilities for creative coding, now available as a modern npm package.
✨ Features
- GPU-accelerated particle systems
- WebGL rendering with three.js
- Creative coding utilities and helpers
- Ready-to-use React component (
Particle) - Modular, extensible architecture
🚀 Installation
npm install @simbashrd/the-particles
# or
yarn add @simbashrd/the-particles🛠 Usage
In React (Next.js or CRA)
import dynamic from 'next/dynamic';
// SSR-safe import for Next.js
const Particle = dynamic(
() => import('@simbashrd/the-particles/dist/Particle'),
{ ssr: false }
);
export default function Home() {
return (
<main>
<h1>My Particle Demo</h1>
<Particle />
</main>
);
}In Vanilla JS
import { createParticles } from '@simbashrd/the-particles';
const container = document.getElementById('my-canvas');
createParticles(container, { /* options */ });📦 API
<Particle />
React component for rendering the particle system.createParticles(container, options)
Vanilla JS function to initialize particles in a DOM element.See USAGE.md for advanced configuration and API details.
🖼 Demo
Check out the demo video above!
📝 License
MIT © [email protected]
🤝 Acknowledgements
- The Spirit is a WebGL experience by Edan Kwan, using noise derivatives and curl noise for a smoky look and feel.
- Inspired by Simo Santavirta's the new particles and David Li's Flow experiment.
