mirror of
https://github.com/react/react.git
synced 2026-09-29 16:57:39 +08:00
Updated OVERVIEW.md to the new infos required when adding a new leaf node to the tree (#19981)
Co-authored-by: Idriss AITHAFID <Idriss.AITHAFID@um6p.ma>
This commit is contained in:
co-authored by
Idriss AITHAFID
parent
f46a80ae11
commit
4890779729
@@ -70,7 +70,7 @@ For example, adding a root fiber with an id of 1:
|
||||
|
||||
#### Adding a leaf node
|
||||
|
||||
Adding a leaf node takes a variable number of numbers since we need to decode the name (and potentially the key):
|
||||
Adding a leaf node to the tree requires sending 7 numbers:
|
||||
|
||||
1. add operation constant (`1`)
|
||||
1. fiber id
|
||||
@@ -88,7 +88,6 @@ For example, adding a function component `<Foo>` with an id 2:
|
||||
1, // ElementTypeClass
|
||||
1, // parent id
|
||||
0, // owner id
|
||||
3, // encoded display name size
|
||||
1, // id of "Foo" displayName in the string table
|
||||
0, // id of null key in the string table (always zero for null)
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user