reading-notes

Class 3

Back to home page

React Docs - lists and keys

Q. What does .map() return?

Q. If I want to loop through an array and display each value in JSX, how do I do that in React?

Q. Each list item needs a unique __.

Q. What is the purpose of a key?

The Spread Operator

Q. What is the spread operator?

Q. List 4 things that the spread operator can do.

Q. Give an example of using the spread operator to combine two arrays.

Q. Give an example of using the spread operator to add a new item to an array.

Q. Give an example of using the spread operator to combine two objects into one.

Examples found on medium.com

How to Pass Functions Between Components

Q. In the video, what is the first step that the developer does to pass functions between components?

Q. In your own words, what does the increment function do?

Q. How can you pass a method from a parent component into a child component?

Q. How does the child component invoke a method that was passed to it from a parent component?

Video link: Passing functions between components

Bookmarks

Things I want to know more about

what is the rest operator and how does it differ from spread?