No...It's not always a good practice. And here, it's a bad one.
It's usefull when you have a function with 3+ parameters, cause it improve usability/readability
it's a bad practice on simple functions especially when you use Javascript :
poor autocompletion
poor readability
risk of silent undefined issues (when JS evaluate an objet property that doesn't exist, it won't throw an error but just returns undefined)
ThemeSelection provide selected high quality, modern design, professional and easy-to-use HTML Themes, Admin Dashboard Template and UI Kits to create your applications faster!
function greet(name = "Guest") {Hello, ${name}return
;}
It is good practice to pass parameters in object rather than this old way, this will save the sequence issue and undefined issue
function greet({name = "Guest"}) {Hello, ${name}return
;}
No...It's not always a good practice. And here, it's a bad one.
It's usefull when you have a function with 3+ parameters, cause it improve usability/readability
it's a bad practice on simple functions especially when you use Javascript :
Thanks for checking out
Thanks for sharing this valuable information 🥰
Thanks for checking out
You're welcome.
How are people still putting these moronic articles out for things that have been here for almost a decade now.
To make JavaScript easier
Learned new things from your post, thank you for sharing with us!!
As a beginner so much useful information, just in one page. Thanks bro.
Thanks for checking out
Nice one, l had to go through to check if l was a really js developer😁
StucturedClone is good to
Great collection..!!
Thanks for sharing.
Thank you for sharing