Run details:
Mozilla/5.0 (Linux; arm_64; Android 13; 2112123AG) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/126.0.6478.116 YaBrowser/24.7.2.116.00 SA/3 Mobile Safari/537.36
Yandex Browser 24
Android
Mobile
4 months ago
Test name Executions per second
classnames 823982.1 Ops/sec
clsx 1124102.1 Ops/sec
Array based 862007.6 Ops/sec
String based (return struct) 1164531.8 Ops/sec
String based (if-else struct) 1156895.2 Ops/sec
Entries, filter, map, join 992677.4 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • classnames

  • clsx

  • Array based

  • String based (return struct)

  • String based (if-else struct)

  • Entries, filter, map, join