Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Functions

  • addQueryEntries(entries: QueryEntry[], uri: Uri): Uri
  • addQueryEntry(query: QueryEntry, uri: Uri): Uri
  • addQueryParams(params: Record<string, any>, uri: Uri): Uri
  • addQueryString(query: string, uri: Uri): Uri
  • appendPath(path: string, uri: Uri): Uri
  • isEqual(a: Uri, b: Uri): boolean
  • parse(uri: string): Uri
  • parseAndAddParams(baseStr: string, params?: Record<string, unknown>): Uri
  • Convenience method to create a URI from a base string and add params if present

    Parameters

    • baseStr: string
    • Optional params: Record<string, unknown>

    Returns Uri

  • pathAsArray(uri: Uri): string[]
  • queryAsArray(uri: Uri): QueryEntry[]
  • Return an array of name/value pairs representing the query string of a URI. The returned names and values will be URI decoded. If the query string is empty, then an empty array is returned.

    Parameters

    • uri: Uri

      A URI to return the query string for.

    Returns QueryEntry[]

  • queryAsMap(uri: Uri): QueryMap
  • Return a map containing a URI's query string names and their values. The returned names and values will be URI decoded. If the query string contains multiple instances of the same name, then the last occurrence will be used.

    If the query string is empty, an empty map is returned.

    Parameters

    • uri: Uri

      A URI to return the query string for.

    Returns QueryMap

  • replaceFragment(fragment: string, uri: Uri): Uri
  • replacePath(path: string, uri: Uri): Uri
  • toString(uri: Uri): string