You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Keys help React identify which items have changed, are added, or are removed. Keys should be given to the elements inside the array to give the elements a stable identity.
1. In the video, what is the first step that the developer does to pass functions between components?
Passing the function as an attribut to the child component, thin in the child component he use props in order to be able to call the function.
2. In your own words, what does the increment function do?
Increasing the count propraprity in the object that its name propraprity matched the paased name in the people array of objects.
3. How can you pass a method from a parent component into a child component?
By passing the function as an attribut to the child component in the component tag, thin in the child component he use props in order to be able to call the function.
4. How does the child component invoke a method that was passed to it from a parent component?
using the props , For Example: this.props.the name of the attribut that holding the method ()