Repository navigation
Conversation
Implement function to display teachers with pets
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
There was a problem hiding this comment.
JS script looks good. Well done! The HTML code have room to improve.
Can you check if any of this general feedback can help you further improve your code?
https://github.com/CodeYourFuture/Module-Data-Flows/blob/general-review-feedback/debugging/book-library/feedback.md
Doing so can help me speed up the review process. Thanks.
|
Sorry for the oversight. I have validated the HTML code. Thanks for the review. |
There was a problem hiding this comment.
This checkbox is not showing due to an issue related to Bootstrap 4.4.1.
Could you use AI to find a way to fix it?
| titleInput.value = ""; | ||
| authorInput.value = ""; | ||
| pagesInput.value = ""; | ||
| readInput.checked = false; |
There was a problem hiding this comment.
Could you explore a simpler way to reset form input?
|
|
||
| myLibrary.splice(i, 1); | ||
| render(); | ||
| message.textContent = `You've deleted title: ${deleteTitle}`; |
There was a problem hiding this comment.
This message will stay forever until it is replaced by another message. Could you find a way to make the display temporary (without using alert())?
| addDefaultBooks(); | ||
| render(); | ||
| addBookButton.addEventListener("click", addBook); |
There was a problem hiding this comment.
Placing all the code that needs to be executed once when the page loads together at the end of the script is a good practice.
You could take this a step further by encapsulating this code in a single function named init() or setup() and assigning that function as the callback for the window's onload event.
This would make it even easier to locate, organize, and manage all the code that runs once when the application starts.
|
Could you also address all comments? |
Learners, PR Template
Self checklist
Task code
CYF-1122
Changelist
Implement functions for Book Library website that allows users to add books, see books they have read and remove books for the list.