Run details:
Mozilla/5.0 (X11; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/115.0
Firefox 115
Linux
Desktop
one year ago
Test name Executions per second
new Intl.DateTimeFormat.format() 16308.3 Ops/sec
cached Intl.DateTimeFormat.format() 401115.2 Ops/sec
new Intl.DateTimeFormat.formatToParts 12979.6 Ops/sec
cached Intl.DateTimeFormat.formatToParts() 187620.2 Ops/sec
Script Preparation code:
Tests:
  • new Intl.DateTimeFormat.format()

  • cached Intl.DateTimeFormat.format()

  • new Intl.DateTimeFormat.formatToParts

  • cached Intl.DateTimeFormat.formatToParts()