Hi, I dont know why it doest pass. I tried many times.
function addEntry() {
const targetId = ‘#’ + entryDropdown.value;
const targetImputContainer = document.querySelector(${targetId} .input-container
);
}
Hi, I dont know why it doest pass. I tried many times.
function addEntry() {
const targetId = ‘#’ + entryDropdown.value;
const targetImputContainer = document.querySelector(${targetId} .input-container
);
}
Hey.
What lesson name is this?
Learn Form Validation by Building a Calorie Counter - Step 39
I do not see a template literal in your code. The contents in the querySelector should be nested in backticks.
I did. Still doesnt work.
Can I see the corrected code?
function addEntry() {
const targetId = '#' + entryDropdown.value;
const targetImputContainer = document.querySelector(`${targetId} .input-container`);
}
I dont know what it missing, I tried adding const templateLiteral =
and nothing.
Something is off here.
I just noticed, fixed!
You are very much welcome.
This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.