Build a Calorie Counter - Step 43

Tell us what’s happening:

I am stuck in step 43 of calorie counter workshop. I have replaced the targetId with entryDropdown.value in the template literal as the instruction says. Yet I can’t pass the step.

Your code so far

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

/* file: styles.css */

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

function addEntry() {
  const targetId = '#' + entryDropdown.value;
  const targetInputContainer = document.querySelector(`#${entryDropdown.value} .input-container`);
}

// 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/145.0.0.0 Safari/537.36

Challenge Information:

Build a Calorie Counter - Step 43

Thanks to template literals, you actually don’t need the targetId variable at all. Remove that variable…

Please read this instruction again. You are overlooking something.

Okay, thank you for your response. I will go back to it.

I got it now, I entirely removed the line that has targetId variable and it worked.