Trusted Types vs String

Benchmark created on


Setup

var p = trustedTypes.createPolicy('x', { createScript(x) { return x; } });

Test runner

Ready to run.

Testing in
TestOps/sec
tt
eval(p.createScript('const a = 1'));
ready
string
eval('const a = 1');
ready

Revisions

You can edit these tests or add more tests to this page by appending /edit to the URL.