You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Challenge Objective:
"Your task is to remove the Effect that recomputes the visibleTodos list in the TodoList component. However, you need to make sure that getVisibleTodos() does not re-run (and so does not print any logs) when you type into the input."
While the first half I did with useMemo, (Valid Challenge)
The second half, where we're supposed to make sure that "getVisibleTodos() does not re-run (and so does not print any logs) when we type into the input" but it is the default behavior of the code, even without any changes to the base starter code, this is how it behaves to begin with. So I feel it's a mistake and should be improved...
The text was updated successfully, but these errors were encountered:
Krishnagopal-Sinha
changed the title
[Mistake]: getVisibleTodos() does not re-run (and so does not print any logs) when you type into the input to begin with!
[Mistake]: getVisibleTodos() does not re-run (and does not print any logs) when you type into the input to begin with!
Mar 7, 2024
@TheMaskedGuy the challenge is to remove the useEffectwhile still not calling getVisibleTodos() every time the input changes:
Your task is to remove the Effect that recomputes the visibleTodos list in the TodoList component. However, you need to make sure that getVisibleTodos() does not re-run (and so does not print any logs) when you type into the input.
Summary
The second objective (highlighted below) of the challenge is the default behavior of the starting base code.
Page
https://react.dev/learn/you-might-not-need-an-effect#challenges
Details
Challenge Objective:
"Your task is to remove the Effect that recomputes the visibleTodos list in the TodoList component. However, you need to make sure that getVisibleTodos() does not re-run (and so does not print any logs) when you type into the input."
While the first half I did with useMemo, (Valid Challenge)
The second half, where we're supposed to make sure that "getVisibleTodos() does not re-run (and so does not print any logs) when we type into the input" but it is the default behavior of the code, even without any changes to the base starter code, this is how it behaves to begin with. So I feel it's a mistake and should be improved...
The text was updated successfully, but these errors were encountered: