A top-level App
component returns <Button />
from its render()
method.
-
What is the relationship between
<Button />
andthis
in thatButton
’srender()
? -
Does rendering
<Button><Icon /></Button>
guarantee that anIcon
mounts? -
Can the
App
change anything in theButton
output? What and how?
this will be the button's instance -> this.setState will set state of the button
<Button><Icon /></Button>
guarantee that an Icon mounts?No. it can skip rendering children
yes, you can clone children elements in the App and change their props, for example, but I don't really understand the question.