Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

std/crypto/mod.ts>KeyStack#indexOf

Deno standard library
Go to Latest
The Standard Library has been moved to JSR. See the blog post for details.
method KeyStack.prototype.indexOf
import { KeyStack } from "https://deno.land/std@0.212.0/crypto/mod.ts";

Given data and a digest, return the current index of the key in the keys passed the constructor that was used to generate the digest. If no key can be found, the method returns -1.

Parameters

data: Data
digest: string

Returns

Promise<number>