Tell us what’s happening:
If the user selects Nicknames
from the dropdown menu you will want to filter out player cards that have a nickname.
Start by adding a case
clause for nickname
inside your switch
statement.
Error: You should add a new case
clause for nickname
inside your switch
statement.
I understand how switch works but not how to put it together? (I guess):
switch (what changes) {
case 1:
code of what happens in case 1
break;
case 2:
code of what happens in case 2
break;
case N:
code of what happens in case N
break;
But I can’t get the test to accept my code, what does it want?
}
Your code so far
//what I’ve tried:
switch (e.target.value) {
case e.target.value=nickname:
}
switch (e.target.value) {
case nickname:
}
switch (e.target.value) {
case 1:
}
switch (e.target.value) {
case e = nickname:
}
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 Edg/120.0.0.0
Challenge Information:
Learn Modern JavaScript Methods By Building Football Team Cards - Step 41