Test name | Executions per second |
---|---|
lodash isNil | 379098208.0 Ops/sec |
native isNil | 267650256.0 Ops/sec |
<script src='https://cdnjs.cloudflare.com/ajax/libs/lodash.js/4.17.5/lodash.min.js'></script>
var a = null;
var b = undefined;
var c = NaN;
var d = false;
var e = 'a';
var f = 0;
_.isNil(a);
_.isNil(b);
_.isNil(c);
_.isNil(d);
_.isNil(e);
_.isNil(f);
a == null
b == null
c == null
d == null
e == null
f == null