I've been tasked with working on some code that I didn't write, but there is a line in this code that I just don't understand.
var headerHeight = window.innerWidth > 1920 ? $('.bottom-header').outerHeight() + $('.bottom-fixed-selector').outerHeight() : 0;
what I do understand is that the question mark is a conditional operator. I had no idea a conditional operator could be used within a variable declaration, however. Is there an alternative way to write this that is easier for me to understand?