0
Hours
0
Minutes
0
Seconds

How to fix and build an Age Validator? | Pair Programming | Frontend Coding Challenge | ReactJS | JavaScript
@Devtools Tech

308

A lot of companies have a specific machine coding round where either you are provided with a PR or a code sample with most of the problem statement being already implemented and you need to fix a certain functionalities or build on top of existing the code. This question follows the same pattern.

In this question, we are build an Age validator. You need to fix the broken parts of the implementation provided by us.

Specifications

Read the below mentioned specifications and make sure all are met.

  1. The system here is an Age Validator. It tells if a user is eligible to use the services or not.
  2. The user's age >= 18 years to use the services i.e. to be eligible.
  3. Date Of Birth is a required field.
  4. If user is eligible then show the success message else ineligible message on form submission.
  5. On form submission, show an error if the DOB is missing.
  6. Clicking on Why do we need to know this? CTA should toggle the message box stating the required information.
  7. Back CTA on the Result screen should take user back to the Validator.

Bonus

  • Make the app accessible by making necessary changes.

Working App Demo

Submission

Please start the timer before starting and finish your solution within 60 mins. Share your solution with us on Twitter or LinkedIn.