DEV Community

Cover image for [Vue.js] How to create beautiful and realistic confetti animations using tsParticles
Matteo Bruni for tsParticles

Posted on • Edited on

7 3

[Vue.js] How to create beautiful and realistic confetti animations using tsParticles

I wrote a post about tsParticles and the new confetti animation created in the 1.30 version.

This configuration can be used as is in any Vue.js 2.x tsParticles installation (particles.vue package).

app.js

import Particles from "particles.vue";

Vue.use(Particles);
Enter fullscreen mode Exit fullscreen mode

home.vue

<!-- this component can be placed anywhere -->
<Particles :options="/* paste options here, remember to replace double quotes with single quotes */" />
Enter fullscreen mode Exit fullscreen mode

A working sample can be found below

GitHub logo tsparticles / tsparticles

tsParticles - Easily create highly customizable JavaScript particles effects, confetti explosions and fireworks animations and use them as animated backgrounds for your website. Ready to use components available for React.js, Vue.js (2.x and 3.x), Angular, Svelte, jQuery, Preact, Inferno, Solid, Riot and Web Components.

Top comments (0)

Image of Datadog

Master Mobile Monitoring for iOS Apps

Monitor your app’s health with real-time insights into crash-free rates, start times, and more. Optimize performance and prevent user churn by addressing critical issues like app hangs, and ANRs. Learn how to keep your iOS app running smoothly across all devices by downloading this eBook.

Get The eBook