Security News
Bun 1.2 Released with 90% Node.js Compatibility and Built-in S3 Object Support
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
@types/keccak
Advanced tools
TypeScript definitions for keccak
npm install --save @types/keccak
This package contains type definitions for keccak (https://github.com/cryptocoinjs/keccak#readme).
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/keccak.
/// <reference types="node" />
import { Transform, TransformOptions } from "stream";
declare namespace createHash {
class Keccak extends Transform {
constructor(
rate: number,
capacity: number,
delimitedSuffix: number | null,
hashBitLength: number,
options: TransformOptions,
);
update(data: string | Buffer, encoding?: BufferEncoding): Keccak;
digest(): Buffer;
digest(encoding: BufferEncoding): string;
}
class Shake extends Transform {
constructor(rate: number, capacity: number, delimitedSuffix: number | null, options: TransformOptions);
update(data: string | Buffer, encoding?: BufferEncoding): Shake;
squeeze(dataByteLength: number): Buffer;
squeeze(dataByteLength: number, encoding: BufferEncoding): string;
}
type KeccakAlgorithm = "keccak224" | "keccak256" | "keccak384" | "keccak512";
type Sha3Algorithm = "sha3-224" | "sha3-256" | "sha3-384" | "sha3-512";
type ShakeAlgorithm = "shake128" | "shake256";
}
declare function createHash(
algorithm: createHash.KeccakAlgorithm | createHash.Sha3Algorithm,
options?: TransformOptions,
): createHash.Keccak;
declare function createHash(
algorithm: createHash.ShakeAlgorithm,
options?: TransformOptions,
): createHash.Shake;
export = createHash;
These definitions were written by odan.
FAQs
TypeScript definitions for keccak
We found that @types/keccak demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
Security News
Biden's executive order pushes for AI-driven cybersecurity, software supply chain transparency, and stronger protections for federal and open source systems.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.