Design comparison
Solution retrospective
In the JS, I made it do a function based on the button that you pressed returning a value, and that value is the operator in the function, I decided to do that so I wouldn't have to make multiple functions with ifs for each button.
What challenges did you encounter, and how did you overcome them?I had trouble at the start cause I didn't know how to calculate the value etc. But ended up getting the idea.
What specific areas of your project would you like help with?The reset button, initial thought was just a reset, but later I noticed that it had trouble because it didn't take off the results, and the span errors appeared in the inputs, so I decided to make a code that would reload the page location.reload()
when you would click it, but when clicked on the button that would update the results, it wouldn't work anymore even though the button was the same as it was before. I did a test with the button out of the div where the JS would change the HTML, and it worked just fine, I don't know why tho and I didn't want to take the reset out of it so I just left it there.
Community feedback
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