Check out my calculator!

Hi everyone, I think I’m just about finished with my calculator and I would love some help looking for bugs:

I’ve had a lot of problems with chaining so the equals button has to be clicked before adding additional operators. This is my first project using React so bear with me :grimacing:


Very unusual and unique calculator design. I like it. You could add some padding to the input field, so the digits wouldn’t stick to the side.
I am not sure that having to press the equals button qualifies as chaining. I’d come up with a way to avoid that. You can either come up with an algorithm to do it (this is what I did and it’s not that hard) or use eval() as I’ve seen a lot of people do in their calculators.
When using - as the operation the input splits in two and the second number prints in a new line pushing the bottom part of the calculator down.
You allow unlimited digits to be entered. Eventually they flow out of the screen.
That includes multiple zeros before a non zero digit. The only time an entry should be allowed to start with 0 is when it starts with 0.
The calculator interprets .dddd as dddd when in fact it should be interpreting it as 0.dddd

I am curious, why did you choose to use React to make the calculator?

Thanks for your feedback, I’m going to work on fixing some of these tonight. As for using React, there wasn’t a particular reason I just wanted more practice with it

This looks really good. I can only add one thing. When there’s only a 0 in the entry box, I can delete it, which leaves the display blank and collapses it.