This project is from TheOdinProject. It consists of building an simple calculator performing basic operators.
https://facinetm14.github.io/Odin_calculator/
- Html
- Css
- JavaScript
-
Performs operators:
- Addition "+"
- Substraction "-"
- Modulo "%"
- Pow "X^"
- Display an operation's result on the screen
- Clean the screen when "C" is clicked
Throughout this project, I utilized some modern css like flexbox and transition to annimate buttons, I played with the DOM, done some refactoring and used notion of callback
to increase my code readibility. For example instead of having to check each operator with conditions or switch, I just pass the function to operate(num1, num2, operatorFunction)
Do you have any feedback ? Yes, please.