A lightweight TypeScript library for creating particles. Dependency free (*), browser ready and compatible with React.js, Vue.js (2.x and 3.x), Angular, Svelte, jQuery, Preact, Inferno, Riot.js, Solid.js, and Web Components
@tsparticles/angular@tsparticles/astro@tsparticles/ember@tsparticles/inferno@tsparticles/jquery@tsparticles/preact@tsparticles/qwik@tsparticles/nextjs@tsparticles/react@tsparticles/riot@tsparticles/solid@tsparticles/svelte@tsparticles/nuxt2@tsparticles/vue2@tsparticles/nuxt3@tsparticles/nuxt4@tsparticles/vue3@tsparticles/webcomponents@tsparticles/wordpressDocumentation and Development references here 📖
This library is available on two of the most popular CDNs and it's easy and ready to use, if you were using particles.js it's even easier.
You'll find the instructions below, with all the links you need, and don't be scared by TypeScript, it's just the source language.
The output files are just JavaScript. 🤩
CDNs and npm have all the sources you need in Javascript, a bundle browser ready (tsparticles.engine.min.js), and
all
files splitted for import syntax.
If you are interested there are some simple instructions just below to guide you to migrate from the old particles.js library.
If you are new to tsParticles, this path is usually the fastest:
@tsparticles/engine and @tsparticles/slimimport { tsParticles } from "@tsparticles/engine";
import { loadSlim } from "@tsparticles/slim";
await loadSlim(tsParticles);
await tsParticles.load({
id: "tsparticles",
options: {
background: {
color: "#0d1117",
},
particles: {
move: {
enable: true,
},
number: {
value: 60,
},
},
},
});
Useful docs for the next step:
@tsparticles/engine and one bundle (@tsparticles/slim is the common default)tsParticles.load(...)@tsparticles/engine + only needed feature packages@tsparticles/slim@tsparticles/allPlease use these hosts or your own to load tsParticles on your projects
https://unpkg.com/@tsparticles/confetti/ https://unpkg.com/@tsparticles/particles/ https://unpkg.com/@tsparticles/engine/ https://unpkg.com/@tsparticles/fireworks/ https://unpkg.com/@tsparticles/basic/ https://unpkg.com/@tsparticles/slim/ https://unpkg.com/tsparticles/ https://unpkg.com/@tsparticles/all/
tsParticles Confetti
tsParticles Particles
tsParticles Engine
tsParticles Fireworks
tsParticles Basic
tsParticles Slim
tsParticles
tsParticles All
npm install @tsparticles/engine
yarn add @tsparticles/engine
pnpm install @tsparticles/engine
const tsParticles = require("@tsparticles/engine");
// or
import { tsParticles } from "@tsparticles/engine";
The imported tsParticles is the same instance you have when including the script in the page using the <script> tag.
Load tsParticles and configure the particles:
index.html
<script src="https://github.com/tsparticles/tsparticles/raw/v4.3.1/tsparticles.engine.min.js"></script>
app.js
```javascript /
$ claude mcp add tsparticles \
-- python -m otcore.mcp_server <graph>