loading...

re: 5 Way to Append Item to Array in JavaScript VIEW POST

FULL DISCUSSION
 

The point about not mutating if you need the array elsewhere is a good one, especially for parallel or concurrent programming. Even in single threaded JavaScript you might have passed an array by reference and so mutate things unexpectedly. Generally I find non-mutation to be a more relaxing method!

 

Yes, great point John! Let me add that to my notes! Thanks for sharing 👏

code of conduct - report abuse