Run details:
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/110.0.0.0 Safari/537.36
Chrome 110
Linux
Desktop
one year ago
Test name Executions per second
value == null 25935138.0 Ops/sec
value == undefined 8856501.0 Ops/sec
value === null 25972438.0 Ops/sec
value === undefined 9010182.0 Ops/sec
value === null || value === undefined 6758680.0 Ops/sec
_.isNil(value) 8646212.0 Ops/sec
value != null 25979566.0 Ops/sec
value != undefined 9027451.0 Ops/sec
value !== null 26032306.0 Ops/sec
value !== undefined 9085471.0 Ops/sec
value !== null && value !== undefined 6721817.0 Ops/sec
!_.isNil(value) 8701693.0 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • value == null

  • value == undefined

  • value === null

  • value === undefined

  • value === null || value === undefined

  • _.isNil(value)

  • value != null

  • value != undefined

  • value !== null

  • value !== undefined

  • value !== null && value !== undefined

  • !_.isNil(value)


;