Get started with tsparticles-move-base CDN
MIT licensed
Library for smooth particle movement, interactions in Three.js with tsparticles-move-base.
Tags:- tsparticles
- particles.js
- particlesjs
- particles
- particle
- canvas
- jsparticles
- xparticles
- particles-js
- particles-bg
- particles-bg-vue
- particles-ts
- particles.ts
- react-particles-js
- react-particles.js
- react-particles
- react
- reactjs
- vue-particles
- ngx-particles
- angular-particles
- particleground
- vue
- vuejs
- preact
- preactjs
- jquery
- angularjs
- angular
- typescript
- javascript
- animation
- web
- html5
- web-design
- webdesign
- css
- html
- css3
- animated
- background
- confetti
- fireworks
- fireworks-js
- confetti-js
- confettijs
- fireworksjs
- canvas-confetti
Stable version
Copied!
How to start using tsparticles-move-base CDN
<!DOCTYPE html>
<html>
<head>
<title>Get started with tsparticles-move-base CDN - cdnhub.io</title>
<style>
#tsparticles {
height: 100vh;
width: 100vw;
background-color: #000;
}
</style>
</head>
<body>
<div id="tsparticles"></div>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/worksans.min.css"></script>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/tsparticles.min.js"></script>
<script src="https://cdn.cdnhub.io/tsparticles-move-base/2.12.0/tsparticles.move.base.min.js"></script>
<script>
const particles = new TSParticles({
container: document.querySelector('#tsparticles'),
backgroundMode: {
enable: true,
color: '#000'
},
fpsLimit: 60,
particles: {
number: {
value: 100,
density: {
enable: true,
valueArea: 800
}
},
color: {
value: '#fff'
},
shape: {
type: 'circle'
},
size: {
value: 5,
random: true,
anim: {
enable: false,
speed: 4,
size_min: 0.1,
sync: false
}
},
opacity: {
value: 0.5,
random: true,
anim: {
enable: false,
speed: 1,
opacity_min: 0.1
}
},
line_linked: {
enable: false,
distance: 150,
color: '#fff',
opacity: 0.4,
width: 1
}
},
interactivity: {
detectsOn: 'canvas',
events: {
onHover: {
enable: true,
mode: 'repulse'
},
onClick: {
enable: true,
mode: 'push'
},
resize: true
},
modes: {
grab: {
distance: 400,
line_linked: {
opacity: 1
}
},
bubble: {
distance: 400,
size: 40,
duration: 2,
opacity: 8,
speed: 3
},
repulse: {
distance: 200,
duration: 0.4
},
push: {
distance: 400,
duration: 0.4
},
remove: {
enabled: true,
quantity: 1
}
}
},
move: {
enable: true,
random: true,
speed: 1,
direction: 'none',
out_mode: 'out',
attract: {
enable: false,
rotateX: 600,
rotateY: 1200
}
},
interactivity: {
detectsOn: 'canvas',
events: {
onHover: {
enable: true,
mode: 'repulse'
},
onClick: {
enable: true,
mode: 'push'
},
resize: true
},
modes: {
grab: {
distance: 400,
line_linked: {
opacity: 1
}
},
bubble: {
distance: 400,
size: 40,
duration: 2,
opacity: 8,
speed: 3
},
repulse: {
distance: 200,
duration: 0.4
},
push: {
distance: 400,
duration: 0.4
},
remove: {
enabled: true,
quantity: 1
}
}
},
components: {
move: {
position: {
x: null,
y: null
},
gravity: {
enable: true,
acceleration: { x: 0, y: 1 }
}
},
moveBase: {
position: {
x: null,
y: null
},
attract: {
enable: true,
rotateX: 600,
rotateY: 1200
}
}
}
});
particles.add(new TSParticles.MoveBase());
particles.moveTo(300, 300);
</script>
</body>
</html>
Copied!
Copied!