JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 2073906
  • Score
    100M100P100Q222569F
  • License MIT

Package Exports

  • math-random

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (math-random) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

math-random

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.

Build status

Install

npm install math-random

Usage

var random = require('math-random')

console.log(random())
=> 0.584293719381094

console.log(random.cryptographic)
=> true || undefined

License

MIT