Function ipnsSubdomain

  • Returns true if the provided url string looks like a valid IPNS subdomain (CIDv1 with libp2p-key multicodec or something that looks like a FQDN, for example en.wikipedia-on-ipfs.org.ipns.localhost:8080) or false otherwise.

    Note: ipnsSubdomain method works in offline mode: it does not perform actual IPNS record lookup over DHT or other content routing method. It may return false-positives:

    • To ensure IPNS record exists, make a call to /api/v0/name/resolve?arg=<ipnsid>
    • To ensure DNSLink exists, make a call to /api/v0/dns?arg=<fqdn>

    Parameters

    Returns boolean

Generated using TypeDoc