JavaScript Calculator - feedback wanted!

Hello!
I finally finished this project after so much sweat, blood and tears…

Please provide some feedback and pointers on how to make the codes less convoluted. I really feel that the structure is shaky, even though the calculator works.

Thanks a lot fellow campers!

Thanks for testing it out!
OK, so I’ve defined the function pressNegate() as this:

function pressNegate(){
if(result !== 0){
        tempArr = [result - (result*2)];
        document.querySelector(display).textContent = result;
    } else {
        //toggle the previously pressed number(s) between + and -
    }
}

Is there a way to toggle without using jquery though? or do I simply have to test using if/else statement?

Sorry, should have remembered that!

So I think I fixed it (and I’ve modified the code so that each time the equals operator is pressed, the calculator only displays the result, not the equation), but there is one small problem remaining.

Say, I do this: 5 + 3 =

The calculator will display 8

If I then press another operand, say a minus, the sub display will show this: 8, -

I don’t know where that comma after the number comes from. Even weirder, when I console logged it, there`s no comma to be seen.

The codepen url again: