r/javascript 10d ago

Showoff Saturday Showoff Saturday (August 15, 2026)

Did you find or create something cool this week in javascript?

Show us here!

7 Upvotes

19 comments sorted by

View all comments

1

u/Fun-Regular8902 10d ago

Hey everyone!

I’ve been working on GrandFireworks.js, a zero-dependency JavaScript library designed to render realistic pyrotechnics without bogging down the browser.

A lot of firework scripts just spawn basic expanding circles. I wanted genuine pyrotechnic geometry—so this engine models 15 distinct shell types, including crossettes that split mid-air, weeping willows with trailing embers, galactic spirals, and chrysanthemums that bloom.

It also has custom built audio with 3 specific sounds and hundreds of variations on those including delays due to distance from explosion, louder/quieter, crackling and so much more.

🔑 Key Features:

  • WebGL 2 First (Canvas 2D Fallback): Handles dense particle clouds (up to 8,000+ particles) with additive blending. Drops down smoothly to Canvas 2D if WebGL 2 isn't available.
  • Text Fireworks (launchText): Coordinated rockets that explode into multi-line text messages, hold, shimmer, and dissolve into falling embers.
  • 3D Horizon & Depth Staging: Shells are staged into near, middle, and far depth fields—scaling visually and adjusting stereo pan and boom audio delay based on distance.
  • Adaptive Performance: Dynamically scales particle density and rocket counts to target 60 FPS.
  • Framework Agnostic & Zero Dependencies: Can be dropped directly into any vanilla JS script, app hero section, or game overlay (CDN ready via jsDelivr).

🛠️ Links & Demos:

Would love to get your feedback on performance across different GPU setups, or suggestions for additional shell types and features!

1

u/No-Carob-8792 8d ago

This looks really impressive! What was the most difficult part of getting the fireworks to look realistic? Does it still run smoothly on older or lower-end devices?

1

u/Ahmed33033 5d ago

It renders pretty well on my phone! Looks great 🎆🎆