Function generateGenesisScriptConfigs

  • Generate ScriptConfig for the genesis block, use this function when you are on a testnet, or you cannot determine which network you are on

    Parameters

    Returns Record<"SECP256K1_BLAKE160" | "SECP256K1_BLAKE160_MULTISIG" | "DAO", config.ScriptConfig>

    Example

    const rpc = new RPC('http://localhost:8114')
    const genesisBlock = await rpc.getBlockByNumber('0x0')
    const scriptConfig = generateGenesisScriptConfigs(genesisBlock)

Generated using TypeDoc