|
|
vor 1 Jahr | |
|---|---|---|
| .. | ||
| .travis.yml | vor 1 Jahr | |
| browser.js | vor 1 Jahr | |
| node.js | vor 1 Jahr | |
| package.json | vor 1 Jahr | |
| readme.md | vor 1 Jahr | |
| test.js | vor 1 Jahr | |
math-random is an drop-in replacement for Math.random that uses cryptographically secure random number generation, where available. It works in both browser and node environments.
npm install math-random
var random = require('math-random')
console.log(random())
=> 0.584293719381094
console.log(random.cryptographic)
=> true || undefined