Skip to content

Add normative algorithm for when to call "fetch a manifest image resource" #1216

Description

@marcoscaceres

Problem

PR #1171 introduces a "fetch a manifest image resource" algorithm but leaves it with no normative call site. Issue #910 is about clarifying how manifest image resources are fetched — the algorithm alone doesn't fully address this without specifying when it should be called.

Browser behaviour (verified in source)

A browser impl check against Chrome and Firefox shows:

  • Chrome (ManifestToWebAppInstallInfoJob): icons are fetched after manifest parsing/validation, via WebContents::DownloadImageInFrame() with initiator_frame_routing_id, tied to the originating renderer frame. Called during the install flow before showing the install dialog.
  • Firefox (Manifest.sys.mjs:prefetch()): icons are fetched just before the install UI is presented, then cached. aWindow.fetch() with mode: "cors" goes through the content window.

Neither browser fetches icons during regular page loads. Both require a live document/window context.

Proposed fix

Add a normative "obtaining manifest icons" step (or similar) within the manifest application/installation flow that calls "fetch a manifest image resource" for each icon. This likely requires first adding a normative installation algorithm to the spec, which is a larger undertaking.

As an interim, PR #1171 adds an informative note on the algorithm explaining when it is intended to be called.

Related

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions