Answer the question
In order to leave comments, you need to log in
Why is an array with data passed to the component through an object?
Actually there is a functional component? What does this mean, why does an array with data advanced into this component need to be placed in an object? Is this a new replacement for props? If you directly write arrList, then it simply will not be found in the function
export const Notes = ({arrList}) => {
Answer the question
In order to leave comments, you need to log in
so done api of functional components. The object in which the props are passed to the function. This is the device of the universe at this local point, humble yourself and do as described in the documentation.
If curly brackets confuse you, you can write
export const Notes = (props) => { // дальше props.arrList
Google about object destructuring in js and understand the principle
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question