@duckduckgo/content-scope-scripts
    Preparing search index...
    • Paint the first candidate that resolves to a displayable image as target's background, skipping any that do not. A verify candidate is HEAD-checked first, because YouTube answers a thumbnail a video does not have with a valid placeholder image under a 404, so its load event alone cannot tell the difference.

      Candidates are probed concurrently to overlap the network, but consumed in priority order, so a fast low-quality thumbnail cannot beat a slower preferred one.

      Parameters

      • target: HTMLElement
      • candidates: { url: string; verify: boolean }[]

        preference order, best first

      • Optionaloptions: { onResult?: (paintedUrl: string | null) => void; signal?: AbortSignal } = {}

      Returns Promise<void>