Interface UrlLoaderOptions

How a UrlLoader reads.

interface UrlLoaderOptions {
    fetchDocument?: ((url) => Promise<{
        url: string;
        contentType: string;
        body: Buffer<ArrayBufferLike>;
    }>);
}

Properties

Properties

fetchDocument?: ((url) => Promise<{
    url: string;
    contentType: string;
    body: Buffer<ArrayBufferLike>;
}>)

Reads an address and answers the last address after redirects, the media type and the body; a server passes guardedFetch here. When absent, the loader reads through the global fetch as before.

Type declaration

    • (url): Promise<{
          url: string;
          contentType: string;
          body: Buffer<ArrayBufferLike>;
      }>
    • Parameters

      • url: string

      Returns Promise<{
          url: string;
          contentType: string;
          body: Buffer<ArrayBufferLike>;
      }>