Options
All
  • Public
  • Public/Protected
  • All
Menu

Module utils/ens

Index

Functions

Const getNameHash

  • getNameHash(name: string): string
  • Get the name hash for an ENS domain, as defined in EIP-137.

    Parameters

    • name: string

    Returns string

Const isValidAddress

  • isValidAddress(address: string): boolean
  • Check if an address is a valid resolved address. Note that this does not do a full check if an address is valid, but it checks for common return values from JSON-RPC calls.

    Parameters

    • address: string

    Returns boolean

Const normalise

  • normalise(name: string): string
  • Normalise a name according to UTS46.

    Parameters

    • name: string

    Returns string

Const resolveName

  • resolveName(network: Network, name: string): Promise<undefined | string>
  • Resolve an ENS name. Returns the resolved address, or undefined if no address was resolved.

    Parameters

    Returns Promise<undefined | string>

Generated using TypeDoc