> Javascript's notion of logical truthiness is extremely difficult to hold in my head.
So it isn't intuitive to you that an empty object and array should both evaluate to true, but neither are equal to true, the empty array is equal to false, and the empty object is neither equal to true _or_ false?
It's because the == operator converts its arguments to be of the same type, and it does so in a rather unintuitive way. This makes it both inefficient and frequently baffling. You pretty much always want === instead, which does not allow comparisons between different types.
So it isn't intuitive to you that an empty object and array should both evaluate to true, but neither are equal to true, the empty array is equal to false, and the empty object is neither equal to true _or_ false?