Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/135.0.0.0 Safari/537.36
Chrome 135
Mac OS X 10.15.7
Desktop
one year ago
Benchmark.js
date convert to timestamp + sort (timezone safe)
452K/s
date convert to date + sort a-b (timezone safe)
286K/s
View exact numbers
| Test name |
Executions per second |
|
✓
sort
|
5,138,477 Ops/sec |
|
manual compare
|
3,104,322 Ops/sec |
|
localcompare
|
2,378,865 Ops/sec |
|
date convert to timestamp + sort (timezone safe)
|
452,021 Ops/sec |
|
date convert to date + sort a-b (timezone safe)
|
285,744 Ops/sec |
Tests:
-
sort
-
localcompare
-
manual compare
-
date convert to date + sort a-b (timezone safe)
-
date convert to timestamp + sort (timezone safe)