I am a little confused about how truthy or falsy values are evaluated in angular. Apparently, when I do the following directly in angular... things work.
if (0) { console.log('not printed'); }
else { console.log('printed'); }
if (1) { console.log('printed'); }
else { console.log('not printed'); }
However, if I pass a value to my controller from the template... then things do NOT work. Why?
function (someValue) {
if (someValue) { console.log('always printed whether someValue is 0 or 1'); }
else { console.log('not printed'); }
...