Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

easy-sha256

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

easy-sha256 - npm Package Compare versions

Comparing version 1.0.1 to 1.0.2

6

example.js

@@ -1,10 +0,10 @@

var sha256 = require("./index.js")
var Sha256 = require("./index.js")
//Regular Example
console.log(sha256.hash("abc")) //Logs "ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad"
console.log(Sha256.hash("abc")) //Logs "ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad"
// Advanced Async Callback Example
sha256.hash("abc",{async:true}).then(function(hash){
Sha256.hash("abc",{async:true}).then(function(hash){
console.log(hash)

@@ -11,0 +11,0 @@ })

{
"name": "easy-sha256",
"version": "1.0.1",
"version": "1.0.2",
"description": "A Simple and Easy way to use SHA256 in the browser or in NodeJS",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -22,8 +22,8 @@ # Easy Sha256

```
var sha256 = require("easy-sha256")
console.log(sha256.hash("abc")) //Logs "ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad"
var Sha256 = require("easy-sha256")
console.log(Sha256.hash("abc")) //Logs "ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad"
```
Browser (include the script tag above in your html)
```
console.log(sha256.hash("abc")) //Logs "ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad"
console.log(Sha256.hash("abc")) //Logs "ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad"
```

@@ -35,3 +35,3 @@

```
sha256.hash("abc",{async:true}).then(function(hash){
Sha256.hash("abc",{async:true}).then(function(hash){
console.log(hash)

@@ -38,0 +38,0 @@ })

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc