Sheffield | 26-Jan-ITP | Daniel Aderibigbe | Sprint 3 | Todo-list - #1152
Closed
Dan2Clouted wants to merge 2 commits into
Closed
Sheffield | 26-Jan-ITP | Daniel Aderibigbe | Sprint 3 | Todo-list #1152Dan2Clouted wants to merge 2 commits into
Dan2Clouted wants to merge 2 commits into
Conversation
Luro91
reviewed
Apr 7, 2026
| } | ||
|
|
||
| export function deleteCompleted(todos) { | ||
| return todos.filter((todo) => todo.completed === false); |
There was a problem hiding this comment.
Well done this works nicely. (FYI: instead of checking for false you could also check for !todo.completed but this is a bit of a personal preference and should be handled according to the projects coding convention)
| // A callback that reads the task description from an input field and | ||
| // append a new task to the todo list. | ||
| // A callback that reads the task description from an input field and | ||
| // append a new task to the todo list.'' |
| // - Store the reference to the <ul> element with id "todo-list" here | ||
| // to avoid querying the DOM repeatedly inside render(). | ||
| // - This variable is declared here to be close to the only function that uses it. | ||
| // Store reference once |
| // We will create each ToDo list item as a clone of this node. | ||
| // - This variable is declared here to be close to the only function that uses it. | ||
| const todoListItemTemplate = | ||
| // Template reference |
Member
|
Closing PR because the January ITP run has finished. Feel free to re-open if you're still working on it. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Learners, PR Template
Self checklist
Changelist
Completed all task