As Which equals operator (== vs ===) should be used in JavaScript comparisons? indicates they are basically identical except \'===\' also ensures type equality
===
Consider a situation when you compare numbers or strings:
if (4 === 4) { // true }
but
if (4 == "4") { // true }
and
if (4 === "4") { // false }
This applies to objects as well as arrays.
So in above cases, you have to make sensible choice whether to use == or ===