Skip to content

London | 26 ITP January | Mouawia Elkhalifa | Sprint 3 | Alarm Clock#1087

Open
MouawiaElkhalifa wants to merge 2 commits intoCodeYourFuture:mainfrom
MouawiaElkhalifa:sprint-3
Open

London | 26 ITP January | Mouawia Elkhalifa | Sprint 3 | Alarm Clock#1087
MouawiaElkhalifa wants to merge 2 commits intoCodeYourFuture:mainfrom
MouawiaElkhalifa:sprint-3

Conversation

@MouawiaElkhalifa
Copy link
Copy Markdown

Learners, PR Template

Self checklist

  • I have titled my PR with Region | Cohort | FirstName LastName | Sprint | Assignment Title
  • My changes meet the requirements of the task
  • I have tested my changes
  • My changes follow the style guide

Changelist

In this PR, I have completed the Alarm Clock assignment for Sprint 3.

@MouawiaElkhalifa MouawiaElkhalifa added the Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. label Mar 24, 2026
Copy link
Copy Markdown
Contributor

@cjyuan cjyuan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Code works fine if a user only clicks the "Set Alarm" button once.
    However, if the user enters a time and then clicks the "Set Alarm" button multiple times, the countdown clock will not display properly.
    Can you fix the issue?

  • You missed updating index.html according to an instruction in readme.md.

@@ -1,4 +1,30 @@
function setAlarm() {}
function setAlarm() {
let timeRemaining = document.getElementById("alarmSet").value;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some unusual input values can make your app behave abnormally. Can you add code to sanitise the input?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks! I have updated the code to sanitize the input using parseInt() and isNaN() to handle unusual values.

@cjyuan cjyuan added Reviewed Volunteer to add when completing a review with trainee action still to take. and removed Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. labels Apr 5, 2026
@MouawiaElkhalifa MouawiaElkhalifa added the Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. label Apr 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. Reviewed Volunteer to add when completing a review with trainee action still to take.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants