Also want to add, that all objects in JavaScript (arrays are objects too) are stored in memory as links and these links are always not null or zero, that's why Boolean({}) === true
, Boolean([]) === true
.
Also this is the reason why same objects (copied by value not the link) are always not equal.
{} == {} // falselet a = {};let b = a; // copying by linkb == a // true