ethers.js/packages/keccak256/index.js

9 lines
274 B
JavaScript
Raw Normal View History

2019-05-15 01:48:48 +03:00
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var sha3 = require("js-sha3");
var bytes_1 = require("@ethersproject/bytes");
function keccak256(data) {
return '0x' + sha3.keccak_256(bytes_1.arrayify(data));
}
exports.keccak256 = keccak256;