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
Not Found
Not Found
Not Found

Submitted

Pretty Close

Pete• 150

@petewk

Desktop design screenshot for the Tip calculator app coding challenge

This is a solution for...

  • HTML
  • CSS
  • JS
2junior
View challenge

Design comparison


SolutionDesign

Solution retrospective


Some alignment issues, re-set button submits and clears fields instead of just clearing

Community feedback

Devika Sujith• 175

@DCoder18

Posted

Hi Pete, Good attempt. The reason why your reset button submits is because you added submit to the type attribute. You don't need this here unless your sending data to an external page. Instead, set it as <input type="button">.

For the reset button, try using a separate reset function. In that function, you can set all your variables like bill, tip, people etc. to 0.

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