Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

std/node/crypto.ts>randomBytes

Deno standard library
Go to Latest
function randomBytes
Re-export
import { randomBytes } from "https://deno.land/std@0.177.0/node/crypto.ts";

Parameters

size: number

Buffer length, must be equal or greater than zero

Returns

Buffer

Parameters

size: number
optional
cb: (err: Error | null, buf?: Buffer) => void