Design comparison
Solution retrospective
I made it, next time will try to take less time compared to this one.
What challenges did you encounter, and how did you overcome them?Took some time to figure out logic which can be used to calculate difference between given dates, with proper validations.
What specific areas of your project would you like help with?I guess there's something somewhere mistake, will be rectified soon.
Community feedback
- @ortalyartsPosted 7 months ago
Hello @ntshpawar!
Your solution is looking really good!
I found some little bugs:
- If I enter a year in the future - I get an error message, but the app makes the age calculation nevertheless :) so I get a negative result. You can just add
return
to your function before the calculation starts if the validations fails. - If I enter a date that is in the near future (like tomorrow) I don't get any error, though I should. To solve this, as part of validation, you could check if the birthday-date is greater then the current date.
I hope you find this helpful! Cheers :)
Marked as helpful0@ntshpawarPosted 7 months agoHey @ortalyarts,
Thank you for your feedback, and sorry, checking this after some weeks so replying late.
Yes, when I posted this solution there were some issues with the calculation logic thought will look into it later and today after 14 15days I am checking this lol, will fix it soon.
Thank you again!
0 - If I enter a year in the future - I get an error message, but the app makes the age calculation nevertheless :) so I get a negative result. You can just add
Please log in to post a comment
Log in with GitHubJoin our Discord community
Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!
Join our Discord