Learn Modern JavaScript Methods By Building Football Team Cards - Step 30

Tell us what’s happening:

Right next to the ${name} expression, add a new embedded expression. Inside that expression, use a ternary operator to check if isCaptain is true. If so, return (Captain) otherwise return an empty string.
this is what it asks for and i feel like i have done what it has asked of me? unless i have missed somthing.

Your code so far

WARNING

The challenge seed code and/or your solution exceeded the maximum length we can port over from the challenge.

Please copy/paste all the editor code showing in the challenge from where you just linked.

<h2>${name} ${isCaptain? Captain:""}</h2>

Your browser information:

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

Challenge Information:

Learn Modern JavaScript Methods By Building Football Team Cards - Step 30

captain is a string, and missing ()

1 Like

ye that done it, feel kinda stupid now

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.