Run details:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/146.0.0.0 Safari/537.36
Chrome 146
Windows
Desktop
27 days ago
Test name Executions per second
Test 1 — eval (UI script): 179579.0 Ops/sec
Test 2 — new Function (UI script, no cache): 198166.2 Ops/sec
Test 3 — new Function (UI script, cached): 264771.3 Ops/sec
Test 4 — script tag (UI script): 47246.5 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • Test 1 — eval (UI script):

  • Test 2 — new Function (UI script, no cache):

  • Test 3 — new Function (UI script, cached):

  • Test 4 — script tag (UI script):