microsoft/vscode-react-native

Public

mirrored fromhttps://github.com/microsoft/vscode-react-nativeAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
b46c1dea2f408007fb3c3ee6cc537d5f85fb0b2c

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

src/common/node/crypto.ts

12lines · modecode

1// Copyright (c) Microsoft Corporation. All rights reserved.
2// Licensed under the MIT license. See LICENSE file in the project root for details.
3
4import * as crypto from "crypto";
5
6export class Crypto {
7 public hash(data: string): string {
8 const hasher = crypto.createHash("sha256");
9 hasher.update(data);
10 return hasher.digest("hex");
11 }
12}