Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Request path contains unescaped characters
Request path contains unescaped characters
Not Found

Submitted

Responsive age calculator app using HTML, SCSS and JS

@asmaahamid02

Desktop design screenshot for the Age calculator app coding challenge

This is a solution for...

  • HTML
  • CSS
  • JS
2junior
View challenge

Design comparison


SolutionDesign

Solution retrospective


Hello devs,

It would be very appreciated if you give me your feedback about the feel and appearance of the app and the code structure.

Thanks in advance for your help

Community feedback

Daniel 🛸 44,230

@danielmrz-dev

Posted

Hello @asmaahamid02!

Your project looks great!

I have one suggestion for you to improve it even more:

  • Using margin is not the best option to center an element. Here's a very efficient (and better) way to place an element in the middle of the page both vertically and horizontally:

📌 Apply this to the body (in order to work properly, don't use position or margins):

body {
    min-height: 100vh;
    display: flex; 
    justify-content: center;
    align-items: center;
}

I hope it helps!

Other than that, great job!

2

@asmaahamid02

Posted

@danielmrz-dev Hello Daniel. I really appreciate your help and attention. Actually I didn'r intend to center the div in the middle of the page but I noticed now that it should be centered and modified the code.

You're absolutely right about not using margins for centering but that was not the purpose of margins in my code.

Thanks alot

1
P

@muthucodes

Posted

The month number keeps increasing continuously. I think there is a bug with how number of months is calculated.

The layout looks accurate and all other functionalities are working well. Loved the way numbers animate to arrive at their value. Also, the label and input border is changing to red if values are not valid. Great attention to detail.

1

@asmaahamid02

Posted

@muthucodes thank you for your honest feedback and attention. I just wonder where the month is increasing? Do you mean in the input or the result? I rechecked it and didn’t find this bug

0
P

@muthucodes

Posted

@asmaahamid02 It keeps increasing in the result. Input for which this happened: 23 / 2 / 2000

Marked as helpful

1

@asmaahamid02

Posted

@muthucodes Thank you so muc. It is fixed now!

0

Please log in to post a comment

Log in with GitHub
Discord logo

Join 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