• Generate Proof-of-Work(PoW) according to the algorithm used in mCaptcha incrementally

    Parameters

    • salt: string

      salt used in PoW computation. Will be provided in PoW requirement

    • phrase: string

      challenge phrase used in PoW computation. Will be provided in PoW requirement

    • difficulty: number

      target difficulty for which PoW should be generated. Will be provided in PoW requirement

    • step: number

      notify progress with nonce after 'n' number of steps

    • fn: ((nonce) => void)

      callback function to notify progress

        • (nonce): void
        • Parameters

          • nonce: number

          Returns void

    Returns Promise<WasmWork>

    • proof-of-work

Generated using TypeDoc