Monthly Archives: January 2012

Truthfulness of empty arrays in Javascript… that’s not cool!

An empty array when cast to Boolean evaluates true, indicating that it is truthy. Boolean([]) true An empty array compared to true evaluates false, indicating that it is not truthy. [] == true false [] == false true And yet … Continue reading

Posted in Uncategorized | Leave a comment