Prefer const Over let Or var
Use let For Loop Control Variables
Follow the first rule and use const wherever you can. But there are some cases where you can’t, like when you’re writing a loop. In that case, you should default to using let. Let is block scoped just like const, but can be re-assigned, as is required by looping constructs like for loops.