Files
Jiachi LiuandGitHub f556189b9d [metadata] Fix streaming metadata was missing in ssr (#75155)
### What

@gnoff helped point out that the current implementation of streaming
metadata is bit broken as it's missing the metadata in SSR but fully
resolved on client. We're seeing it inside the `<head>` is because it's
fully resolved by client rather than server, which means it wasn't
correctly "streaming" metadata on server side.

We should still `use()` the promise, and let it hit suspense boundary on
server so the `<head`> won't contain metadata on server. then when it's
finally resolved, it can be emitted through body with the
`useServerInsertedHTML` API, and the condition can be much simpler.

Improved the tests with more assertions where we need to differentiate
wheather the metadata ended in `head` or `body`

Closes NDX-629
2025-01-21 23:28:24 +01:00
..