mirror of
https://github.com/hanzoai/next.js.git
synced 2026-09-24 17:00:51 +00:00
### 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