Function toURL

  • Converts the input into a URL object.

    Parameters

    • input: URLInput

      The input to convert into a URL. It can be a URL object, a string, or an object with URL properties.

    • Optional base: URLInput

      The base URL to resolve relative URLs against.

    Returns URL

    The converted URL object.

    Throws

    Error if the input is not a valid URL.

Generated using TypeDoc