Created
April 29, 2014 19:03
-
-
Save DForshner/11408994 to your computer and use it in GitHub Desktop.
How console.assert() behaves with undefined, null, and zero values.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var isNull = null; | |
| console.log(isNull); | |
| console.assert(isNull); | |
| var isUndefined; | |
| console.log(isUndefined); | |
| console.assert(isUndefined); | |
| var isZero = 0; | |
| console.log(isZero); | |
| console.assert(isZero); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment