Skip to content

[#669] Declarative partial update use case - #958

Merged
rviscomi merged 16 commits into
mainfrom
669-declarative-partial-update
Sep 17, 2026
Merged

rviscomi merged 16 commits into
mainfrom
669-declarative-partial-update

Conversation

@jamesnw

@jamesnw jamesnw commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

A full use case here would require a server streaming HTML slowly, which seems out of scope for this project. Would it suffice to have the demo just show the fully loaded HTML, which would still demonstrate the template replacement? The demo.html here copied from the official example shows what I mean. The guide could mention the server needs but not include code for the server side.

I suspect this won't pass CI without a web feature.

Also, should this be in performance rather than UX?

@jamesnw jamesnw linked an issue Jun 25, 2026 that may be closed by this pull request
1 task
@jamesnw jamesnw mentioned this pull request Jun 25, 2026
@rviscomi
rviscomi requested a review from tunetheweb June 30, 2026 18:24

@tunetheweb tunetheweb left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See comment here regarding whether we should even add this yet:

#669 (comment)

But maybe it's OK to add this simple use case? But I have a few comments on that first.

Comment thread guides/user-experience/streaming-html-updates/demo.html Outdated
Comment thread guides/user-experience/streaming-html-updates/guide.md Outdated
Co-authored-by: Barry Pollard <barrypollard@google.com>
@rviscomi rviscomi removed their assignment Jul 22, 2026
@rviscomi
rviscomi requested a review from tunetheweb July 24, 2026 17:49
@rviscomi

rviscomi commented Aug 5, 2026

Copy link
Copy Markdown
Member

@jamesnw is this ready for another review?

@jamesnw

jamesnw commented Aug 9, 2026

Copy link
Copy Markdown
Contributor Author

@jamesnw is this ready for another review?

@rviscomi Yes, but the blocker is now this question, on whether it is too early to add this to MWG.

@rviscomi

Copy link
Copy Markdown
Member

@rviscomi Yes, but the blocker is now this question, on whether it is too early to add this to MWG.

Ah ok, I missed that. I'll reply there. Thanks!

@jamesnw

jamesnw commented Aug 19, 2026

Copy link
Copy Markdown
Contributor Author

This now is a higher level guide, as recommended here.

Comment thread guides/performance/out-of-order-html-streaming/guide.md Outdated
jamesnw and others added 3 commits August 20, 2026 21:23

@tunetheweb tunetheweb left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apologies for the delay here and we'll wait for web-platform-dx/web-features#4318 but have some comments in the meantime.

Comment thread features/pending-web-features.json Outdated
Comment thread guides/performance/out-of-order-html-streaming/guide.md Outdated
Comment thread guides/performance/out-of-order-html-streaming/guide.md Outdated
Comment thread guides/performance/out-of-order-html-streaming/guide.md Outdated
Comment thread guides/performance/out-of-order-html-streaming/guide.md Outdated
Comment thread guides/performance/out-of-order-html-streaming/guide.md Outdated
Comment thread guides/performance/out-of-order-html-streaming/guide.md Outdated
Co-authored-by: Barry Pollard <barrypollard@google.com>

@tunetheweb tunetheweb left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM but since we've waited this long let's give it a few more days to see if we can resolve web-platform-dx/web-features#4318 as that might need some more changes here.

Comment thread guides/performance/out-of-order-html-streaming/guide.md Outdated
Comment on lines +112 to +113
{{ BASELINE_STATUS("html-setters") }}
{{ BASELINE_STATUS("html-streaming-setters") }}

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These are failing for now.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You could prefix these with tmp- to silence the CI checks, if you did want to merge these changes now. We'll automatically catch when the next version of web-features includes the feature IDs and remove the prefix. But it's also fine to wait for the new IDs to propagate.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That doesn't work in the {{ BASELINE_STATUS() }} macro- there's no check built in for the pending web features.

(It even fails if you comment out (<!-- {{ BASELINE_STATUS("tmp-html-setters") }} -->) the feature, although I guess that makes sense since macros can insert content into comments)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh interesting, that sounds like a bug. Let me know if you want to merge this as-is and this is the only blocker, then I can look into a fix. Otherwise the easiest thing would be to wait until the feature ID is published.

Alternatively you could do something like this, and in the next web-features update PR, we'll get a CI check telling us to remove the tmp prefix and we can resolve this TODO while we're in there.

Suggested change
{{ BASELINE_STATUS("html-setters") }}
{{ BASELINE_STATUS("html-streaming-setters") }}
<!-- TODO: Use macros
BASELINE_STATUS("html-setters")
BASELINE_STATUS("html-streaming-setters")
-->

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No rush to merge this. Especially as half of it isn’t available until 154 anyway. Though the fact you have to use polyfills for other browsers anyway means you could use it now.

Anyway let’s five it a little longer.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is released, so I've removed the tmp features. We'll need to wait until web-features gets updated to 3.39.0 on this repo.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just merged #1468 bumping our version to 3.39.0

@rviscomi rviscomi added the content Pertaining to what the guidance instructs label Sep 12, 2026
@jamesnw

jamesnw commented Sep 17, 2026

Copy link
Copy Markdown
Contributor Author

@tunetheweb I added an example of textStream() here, which would close #1333. I don't think that needs a separate use case.

@jamesnw jamesnw linked an issue Sep 17, 2026 that may be closed by this pull request
@tunetheweb

Copy link
Copy Markdown
Member

@tunetheweb I added an example of textStream() here, which would close #1333. I don't think that needs a separate use case.

Agreed.

@rviscomi

Copy link
Copy Markdown
Member

This is ready to merge. (This is initially written as a discipline guide, rather than a use case, without demo or expectation files.)

@rviscomi
rviscomi merged commit 9de7f15 into main Sep 17, 2026
11 checks passed
@rviscomi
rviscomi deleted the 669-declarative-partial-update branch September 17, 2026 21:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

content Pertaining to what the guidance instructs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Declarative partial updates textStream() for response/request/blob

4 participants