title: i keep getting this error "Cannot read property 'map' of undefined"
body: <pre><code>
      TypeError: Cannot read property 'map' of undefined
        ClassCard
        C:/Users/hp/Desktop/abe2021/src/components/ClassList/ClassCard.js:8
           5 | 
           6 | const ClassCard = ({Names}) =&gt; {
           7 | 
        &gt;  8 |    const cardComp = Names.map((Names, i) =&gt; {
             | ^   9 |        return &lt;ClassList 
          10 |        key={i} 
          11 |        id={Names[i].id} 
  </code></pre>
  
  <p>i am trying to map through an arrary in my react project and i keep getting  the error above</p>