Task is to create variable that checks whether one of three values is true.What is wrong?
Your code so far
<!-- file: index.html -->
/* file: styles.css */
/* file: script.js */
// User Editable Region
closeTaskFormBtn.addEventListener("click", () => {
confirmCloseDialog.showModal();
const formInputsContainValues=titleInput.value.trim()!==''||dateInput.value.trim()!==''||descriptionInput.value.trim()!==''
});
// 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/134.0.0.0 Safari/537.36 Edg/134.0.0.0
Challenge Information:
Learn localStorage by Building a Todo App - Step 34
I feel like the tests should allow checking for an empty string.
Especially considering the tests are accepting a null check for some reason. Checking for an empty string seems a lot more reasonable than a null check. Not even sure the value can be null, isn’t the value property always a string (empty or otherwise)?
not what I meant, also using the OR operator you are in a boolean context, you don’t need the Boolean function for elements to be treated as truthy or falsy