The next step is to create a function that will detect when a user makes a selection from the playersDropdownList.
Use the .addEventListener() method on playersDropdownList. Inside the event listener, pass in a change event type and an empty callback function.
Your code so far
playersDropdownList.addEventListener('change', function() {
});
//I tried this one too, same error. playersDropdownList.addEventListener(change, function() {
});
Error: Your event listener should have an empty callback function.
Challenge Information:
Learn Modern JavaScript Methods by Building Football Team Cards - Step 35
From what I can see, you need to actually use the name of the function after change or write out the entire function.
What is function() {} doing? Does it go anywhere or say what to do?
It is great that you solved the challenge, but please don’t post your full working solution.
We are trying to cut back on the number of spoiler solutions found on the forum and instead focus on helping other campers with their questions and definitely not posting full working solutions.