DEV Community

Discussion on: JavaScript/Typescript Tips compilation 2021🚀

 
nombrekeff profile image
Keff

That's true, I can agree with that. The example was a weird use-case, but entries has some uses though.

Funny, on my test benchmark I realized that a regular for is slower than forEach in that particular example, wich surprised me a bit. I'm guessing the engine is doing some optimization, which are not done for regular fors...