sha256-pow
v0.1.9
Published
```js import init, { mine, verify } from 'https://deno.land/x/[email protected]/sha256_pow.js';
Downloads
1
Readme
sha256-pow
import init, { mine, verify } from 'https://deno.land/x/[email protected]/sha256_pow.js';
await init();
const target = "00000021e800000000000000000000000000000000000000000000000000000";
const powBuffer = new TextEncoder().encode("Hello, PoW!");
const pow = await mine(powBuffer, target);
console.log("Can verify PoW?", verify(pow, target));