It often does not make sense to just compare only includes vs has.
If we can not create the Set beforehand to be reused, and we need to initialize it every time, it will probably deteriorate the performance and we are better off using just simple include most of the times.
Memory measurements supported only in Chrome.
For precise memory measurements Chrome must be launched with --enable-precise-memory-info flag.
More information: Monitoring JavaScript Memory
Test case name
Result
includes
lookup
Fastest:N/A
Slowest:N/A
Latest run results:
Run details: (Test run date:
7 months ago)
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36 SberBrowser/13.0.7.0