UNPKG

as-pedersen

Version:

A pedersen hash implementation in AssemblyScript

12 lines (9 loc) 321 B
const fs = require('fs'); const path = require('path'); const imports = { /* imports go here */ }; const compiled = new WebAssembly.Module( fs.readFileSync(path.join(__dirname, '/build/release.wasm')) ); Object.defineProperty(module, 'exports', { get: () => new WebAssembly.Instance(compiled, imports).exports, });