function randomInRange(min, max) { return Math.random() * (max - min) + min; } function doTheConfetti() { confetti({ angle: 100, spread: randomInRange(70, 120), particleCount: randomInRange(100, 200), origin: { y: 0.6 } }); }