DEV Community

Discussion on: Extract Functions Arguments using Destructure in JavaScript

 
samanthaming profile image
Samantha Ming

For sure, in this simple example, the rest+destructuring combo doesn't really make sense. I'd stick with the 2nd way for sure πŸ‘I think the community example was just showing a different way of doing things that achieve the same thing. Coding is all about communication, so we should pick the one that best facilitates that. I always enjoy seeing all the different ways because it builds up my toolbox. The best tool is always dependent on the situation. Thanks for pointing this out and allowing me to adjust my code notes πŸ™‚