extractIPFSUri

Extracts the IPFS URI from the given bytecode.

Example

import { extractIPFSUri } from "thirdweb/utils/bytecode/extractIPFS";
const bytecode =
"0x363d3d373d3d3d363d30545af43d82803e903d91601857fd5bf3";
const ipfsHash = extractIPFSUri(bytecode);
console.log(ipfsHash);
function extractIPFSUri(bytecode: string): string | undefined;

Parameters

The bytecode to extract the IPFS URI from.

Type

let bytecode: string;

Returns

let returnType: string | undefined;

The IPFS URI if found, otherwise undefined.