getRandomBytes()function
getRandomBytes(length: number): Bytes
| Param | Type | |
|---|---|---|
length | number | The number of random bytes to generate. required |
Get cryptographically-random bytes from the platform crypto API.
Examples
getRandomBytes(16) // Uint8Array(16) [ ... ]