Skip to main content

CommonGet

Callable

  • CommonGet(Path: string, Callback: (this: XMLHttpRequest, xhr: XMLHttpRequest) => void, RetriesLeft?: number): void

  • AJAX utility to get a file and return its content. By default will retry requests 10 times


    Parameters

    • Path: string

      Path of the resource to request

    • Callback: (this: XMLHttpRequest, xhr: XMLHttpRequest) => void

      Callback to execute once the resource is received

      • optionalRetriesLeft: number

        How many more times to retry if the request fails - after this hits zero, an error will be logged

      Returns void

      • Nothing