Skip to main content
The Deno 2 Release Candidate is here
Learn more
Module

x/bcrypt/src/main.ts>hash

A port of jBCrypt to TypeScript for use as a Deno module
Latest
function hash
import { hash } from "https://deno.land/x/bcrypt@v0.4.1/src/main.ts";

Generate a hash for the plaintext password Requires the --allow-net flag

Parameters

plaintext: string

The password to hash

optional
salt: string | undefined = [UNSUPPORTED]

Returns

Promise<string>

The hashed password