Re: [w3c/manifest] Let user agents process a manifest for a document with no manifest link, and choose the display mode (PR #1255)

@dmurph commented on this pull request.



> @@ -1885,6 +1885,18 @@ <h3>
             </p>
           </aside>
         </section>
+        <section>
+          <h3>
+            Processing a document without a manifest link
+          </h3>
+          <p>
+            A [=document=] can also have no manifest link. The user agent MAY
+            still [=processing a manifest|process a manifest=] for that
+            [=document=], passing its [=Document/URL=] as both |document
+            URL:URL| and |manifest URL:URL|, an empty [=byte sequence=] as

Nit: `manifest URL` (around line 181) is currently defined as "the URL from which the manifest was fetched." Since nothing is fetched here, consider updating that definition to add something like ", or the document's URL when processed without a manifest link" to keep it consistent (much smaller change than making `manifest URL` nullable everywhere).

> +        [=display mode=]. The exception is a [=manifest=] that the user agent
+        processed for a [=document=] with no manifest link: for that
+        [=manifest=], the user agent MAY use any [=display mode=] it supports
+        as the [=applied display mode=].

Nit: This exception is only in the prose above `fallback chain`, while the preceding paragraph says the initial `applied display mode` is the result of running `steps for determining the web app's chosen display mode`. Because `process the display member` sets `manifest["display"]` to `"browser"`, step 2 of that algorithm will always return `"browser"`. Consider adding an optional step to `steps for determining the web app's chosen display mode` (or qualifying the preceding sentence) so the algorithm and prose agree. (Minor sub-nit: `manifest` doesn't currently store a flag recording that it was processed without a manifest link, though prose is probably fine here.)

> @@ -3097,7 +3109,10 @@ <h2>
         valid [=manifest/display=] member, the user agent uses the [=display
         mode/browser=] [=display mode=] as the [=applied display mode=]. As
         such, the user agent MUST support the [=display mode/browser=]
-        [=display mode=].
+        [=display mode=]. The exception is a [=manifest=] that the user agent
+        processed for a [=document=] with no manifest link: for that

Quick check: limiting this exception to documents with no manifest link means a document linking to `{}` (no `display` member) still defaults to `browser` unless the user switches display modes (covered by the sentence above). That seems reasonable so we don't override a manifest that intentionally omits `display`, just want to confirm it's intentional.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/w3c/manifest/pull/1255#pullrequestreview-6192577840
You are receiving this because you are subscribed to this thread.

Message ID: <w3c/manifest/pull/1255/review/6192577840@github.com>

Received on Friday, 4 December 2026 16:24:34 UTC