Skip to content

exquisiteOntologist/wasm-random

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

WASM Random

Simple WebAssembly random number generator.

Why

A selection of random number libraries are available; however, few of those libraries are compatible with WASM. This library is designed to be simple and easy to use with WASM.

Compatibility

This library does not depend on any system-specific features, making it compatible with a wide range of environments including WASM (wasm32-unknown-unknown).

Usage

let random_number = wasm_random::random();
let random_number = wasm_random::random_from_range(100., 300.);

There are also ..._f64 variants of these functions (the default are f32).

About

Simple WASM-friendly random number generator

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages