Big News: Socket raises $60M Series C at a $1B valuation to secure software supply chains for AI-driven development.Announcement
Sign In

@types/create-hash

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/create-hash

TypeScript definitions for create-hash

ts4.3
ts4.4
Source
npmnpm
Version
1.2.3
Version published
Weekly downloads
49K
13.59%
Maintainers
1
Weekly downloads
 
Created
Source

Installation

npm install --save @types/create-hash

Summary

This package contains type definitions for create-hash (https://github.com/crypto-browserify/createHash).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/create-hash.

index.d.ts

// Type definitions for create-hash 1.2
// Project: https://github.com/crypto-browserify/createHash
// Definitions by: BendingBender <https://github.com/BendingBender>,
//                 Konstantin Yuriev <https://github.com/gallowsmaker>,
//                 Max Boguslavskiy <https://github.com/maxbogus>,
//                 Jordan Sexton <https://github.com/jordansexton>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.1

/// <reference types="node" />

declare namespace createHash {
    type TypedArray =
        | Uint8Array
        | Uint8ClampedArray
        | Uint16Array
        | Uint32Array
        | Int8Array
        | Int16Array
        | Int32Array
        | Float32Array
        | Float64Array;

    interface HashAlgorithm {
        digest(target: encoding): string;
        digest(): Buffer;

        update(data: string | Buffer | TypedArray | DataView, encoding?: string): this;
        write(data: string | Buffer | TypedArray | DataView, encoding?: string): this;

        end(): void;
        read(): void;
    }

    type encoding = "utf8" | "hex" | "base64";
    type algorithm =
        | "md5"
        | "rmd160"
        | "ripemd160"
        | "sha"
        | "sha1"
        | "sha224"
        | "sha256"
        | "sha384"
        | "sha512";
}

declare function createHash(algorithm: createHash.algorithm, options?: any): createHash.HashAlgorithm;

export = createHash;

Additional Details

  • Last updated: Mon, 04 Sep 2023 15:41:20 GMT
  • Dependencies: @types/node
  • Global values: none

Credits

These definitions were written by BendingBender, Konstantin Yuriev, Max Boguslavskiy, and Jordan Sexton.

FAQs

Package last updated on 04 Sep 2023

Did you know?

Socket

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.

Install

Related posts