Thanks for this comment 😁, but I totally disagree with you.
Thinking about performance before profiling you code is called "premature optimization" which is a known to be a bad thing in software development, also because without appropriate tests, you don't even know where the "bottlenecks" really are.
Furthermore, 90% of the time you don't have performance problems nor this type of operations leads to performance issues (unless you work with long long long arrays). Also, often performance problems are present due to bad software architecture.
Finally, if you want really performant code maybe you need to consider other solutions than JS 😅
Thanks for this comment 😁, but I totally disagree with you.
Thinking about performance before profiling you code is called "premature optimization" which is a known to be a bad thing in software development, also because without appropriate tests, you don't even know where the "bottlenecks" really are.
Furthermore, 90% of the time you don't have performance problems nor this type of operations leads to performance issues (unless you work with long long long arrays). Also, often performance problems are present due to bad software architecture.
Finally, if you want really performant code maybe you need to consider other solutions than JS 😅
Thanks. I'd look into that.