NewUrlForResourceCallback: ((resource: Resource) => string | Promise<string>)

Type declaration

    • (resource: Resource): string | Promise<string>
    • Function for choosing a new URL for a subresource.

      Can be defined via the newUrlForResource option.

      Returns

      The new URL for linking to this subresource.

      Parameters

      • resource: Resource

        The resource to give a (new) URL.

      Returns string | Promise<string>