How it works
Each number comes from crypto.getRandomValues, the browser’s
cryptographically secure random number generator, mapped into your chosen
range. Both endpoints are included, and minimum and maximum can be given in
either order.
Why not Math.random?
Math.random() is fine for animations or shuffling a game board, but its
output can be predictable enough in some browser engines to reconstruct
past or future values. crypto.getRandomValues is the same primitive used
for generating encryption keys — suitable for anything where
unpredictability actually matters, like a drawing or a raffle.
Independent draws
Each number in a batch is generated independently, so repeats are possible by design — the same way a real die can land on the same face twice in a row.