Commit 1f7a2f5
authored
[Float] support title tags as Resources (#25508)
Adds a category of Resources of type `head` which will be used to track
the tags that go into the <head>
Currently only implements for `<title>`.
titles are keyed off their textContent so each time the title changes a
new resource will be created. Currently insertion is done by prepending
in the <head>. The argument here is that the newest title should "win"
if there are multiple rendered. This also helps when a navigation or
update causes a server rendered title to hang around but it is not the
most recent one.1 parent c635807 commit 1f7a2f5
File tree
12 files changed
+801
-112
lines changed- packages
- react-dom-bindings/src
- client
- server
- react-dom/src/__tests__
- react-reconciler/src
12 files changed
+801
-112
lines changedLines changed: 12 additions & 8 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
11 | | - | |
12 | | - | |
13 | | - | |
14 | | - | |
| 10 | + | |
15 | 11 | | |
16 | 12 | | |
17 | 13 | | |
| |||
53 | 49 | | |
54 | 50 | | |
55 | 51 | | |
| 52 | + | |
56 | 53 | | |
57 | 54 | | |
58 | 55 | | |
| |||
282 | 279 | | |
283 | 280 | | |
284 | 281 | | |
285 | | - | |
286 | | - | |
287 | | - | |
| 282 | + | |
288 | 283 | | |
289 | 284 | | |
290 | 285 | | |
291 | 286 | | |
292 | 287 | | |
| 288 | + | |
293 | 289 | | |
294 | 290 | | |
295 | 291 | | |
296 | 292 | | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
0 commit comments