JS Comparison Table (original) (raw)
== (negated: !=)
When using two equals signs for JavaScript equality testing, some funky conversions take place.
=== (negated: !==)
When using three equals signs for JavaScript equality testing, everything is as is. Nothing gets converted before being evaluated.
A standard IF statement. If(value) {/*- green -*/} else { /*- white -*/ }
Note: This row does not match up with any of the rows in the other table.
Moral of the story:
Always use 3 equals unless you have a good reason to use 2.