Skip to content

Std.Random

effect Random

Random values.

  • fn int() -> Int

    Uniform over the whole range of Int.

  • fn float() -> Float

    Uniform in [0, 1).

handler SystemRandom: Random

The host’s random source (JS crypto.getRandomValues, C arc4random_buf or getrandom; cryptographically secure). Stateless.