1.0.5 • Published 6 months ago

particlex v1.0.5

Weekly downloads
-
License
ISC
Repository
-
Last release
6 months ago

Particlex

A simple and easy-to-use library to create particles in your website.

Installation

npm

$ npm i css-particles

HMTL Library

<script src="https://aneks1.github.io/particlex/particlex.umd/index.js"></script>

Usage

Create the Particle System

import cssParticles from 'particlex'
const canvas = document.getElementById('canvas') as HTMLCanvasElement
const system = new cssParticles.ParticleSystem(canvas, { x: canvas.width, y: canvas.height })

Set the ammount of particles to show

system.ammount = 100

Set the properties for the particles

system.speed = { x: { min: -5, max: 5 }, y: { min: -5, max: 5 } }
system.diameter = { min: 1, max: 4 },
system.life = { min: 5, max: 15 }

Init the particle system

system.init()
1.0.5

6 months ago

1.0.4

6 months ago

1.0.3

8 months ago

1.0.2

8 months ago