# WebCryptoSha2Hash | Stacks.js 1.4.1 Library Reference
Documentation for Stacks.js 1.4.1 Library Reference

### Hierarchy

- WebCryptoSha2Hash

### Implements

- Sha2Hash

## Index

### Constructors

- constructor

### Properties

- subtleCrypto

### Methods

- digest

## Constructors

### constructor

- new WebCryptoSha2Hash(subtleCrypto: SubtleCrypto): WebCryptoSha2Hash

- - Defined in packages/encryption/src/sha2Hash.ts:33

  #### Parameters

  - ##### subtleCrypto: SubtleCrypto

  #### Returns WebCryptoSha2Hash

## Properties

### subtleCrypto

subtleCrypto: SubtleCrypto

- Defined in packages/encryption/src/sha2Hash.ts:33

## Methods

### digest

- digest(data: Buffer, algorithm?: string): Promise<Buffer>

- Implementation of Sha2Hash.digest

  - Defined in packages/encryption/src/sha2Hash.ts:39

  #### Parameters

  - ##### data: Buffer

  - ##### algorithm: string = 'sha256'

  #### Returns Promise<Buffer>

Generated using TypeDoc