In order to avoid being able to input “9+0.8.1” for example (double decimals)…I added an if statement to my decimal button click function but am getting an error message…I tried both .includes and .indexOf…
I haven’t looked through the whole logic of your calculator, but the type of userInput after pressing “0” is number (if used on its own or after an operator). includes and indexOf are String methods and therefore don’t exist on number.