HTML Preparation code:
Script Preparation code:
Tests:
Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results
  • Test case name Result
    classnames
    clsx
    Array based
    String based (return struct)
    String based (if-else struct)
    Entries, filter, map, join

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 2 years ago)
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36
Chrome 120 on Mac OS X 10.15.7
View result in a separate tab
clsx
4.8M/s
String based (return struct)
4.6M/s
String based (if-else struct)
4.5M/s
Entries, filter, map, join
4.1M/s
Array based
3.4M/s
classnames
3.3M/s
View exact numbers
Test name Executions per second
clsx 4,819,606 Ops/sec
String based (return struct) 4,555,700 Ops/sec
String based (if-else struct) 4,549,455 Ops/sec
Entries, filter, map, join 4,075,785 Ops/sec
Array based 3,427,542 Ops/sec
classnames 3,346,118 Ops/sec