3rd-Party Plugins

Canvas Confetti

Canvas Confetti is a lightweight library for creating celebratory particle effects—basic cannon blasts, fireworks, stars, snow, and custom shapes—in the browser.

Installation

Canvas Confetti is installed via NPM as a third-party dependency by referring to package.json . During the Theme Installation process, it is copied by the Build Tools into the /dist/assets/vendors/canvas-confetti directory.

Require Assets

To use Canvas Confetti in your pages, include the following script in the order shown.
				
					<!DOCTYPE html>
<html>
 <head>
  <!--Core styles-->
  <link href="/dist/assets/css/styles.css" rel="stylesheet"/>
 </head>
 <body>
  <h1>
   Hello world!
  </h1>
  <!--Core bundle script-->
  <script src="/dist/assets/js/core.bundle.js">
  </script>
  <!--Vendor script -->
  <script src="/dist/assets/vendors/canvas-confetti/canvas-confetti.min.js">
  </script>
  <!--Custom script -->
  <script src="/dist/assets/pages/plugins/canvas-confetti/basic-cannon.js">
  </script>
 </body>
</html>

				
			

Basic Cannon

A single blast of confetti from the center of the viewport. Click the button to fire.

Random Direction

Confetti in random directions with random particle count. Click the button to fire.

Fireworks

Repeated bursts from the sides of the viewport for a fireworks effect. Click the button to run.

Stars

Star-shaped confetti for a celebratory burst. Click the button to fire.

Snow

Gently falling snow-like particles across the viewport. Click the button to start.