Learn Modern JavaScript Methods by Building Football Team Cards - Step 25

Tell us what’s happening:

I feel like this should be easy. I did the return in the div and then outside the div with ${player-card}. what am I missing?

Your code so far

<!-- file: index.html -->

/* file: styles.css */

/* file: script.js */
// User Editable Region


  playerCards.innerHTML += arr.map(
    ({ name, position, number, isCaptain, nickname }) => {
     return `<div class = "player-card" </div>`
    }
  );


// User Editable Region

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/132.0.0.0 Safari/537.36 Edg/132.0.0.0

Challenge Information:

Learn Modern JavaScript Methods by Building Football Team Cards - Step 25

and I removed the space in the div

Hi. You’ve missed the closing tag on your opening div element.

where? I have the /div statement

after your class attribute. I would close the gaps each side of the equal sign as well but that probably wouldn’t make it fail on its own.

I did both. I actually updated it to say I removed the space. But I dont see what you are referring to as missing. I see it

({ name, position, number, isCaptain, nickname }) => {
<div class="player-card" </div>
}

);

Here

<div class = "player-card" </div>

You are missing the >

Remember the syntax for an element in HTML? Your closing tag is fine, the opening one doesn’t have a closing tag.

1 Like

oohhhhhh omg wow I can’t believe I didn’t see it

1 Like