Run details:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/110.0.0.0 Safari/537.36
Chrome 110
Windows
Desktop
one year ago
Test name Executions per second
value == null 22648724.0 Ops/sec
value == undefined 8253411.5 Ops/sec
value === null 22412292.0 Ops/sec
value === undefined 8241185.5 Ops/sec
value === null || value === undefined 6117392.0 Ops/sec
_.isNil(value) 8129659.0 Ops/sec
value != null 22435878.0 Ops/sec
value != undefined 8254472.0 Ops/sec
value !== null 22674904.0 Ops/sec
value !== undefined 8236294.0 Ops/sec
value !== null && value !== undefined 6040316.0 Ops/sec
!_.isNil(value) 8174815.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)


;