you can pass an object literal to a function parameter allowing you to provide arguments in any order and to fallback to default values if arguments are not provided
the code you see is a common pattern that uses truthy and falsy values to create default values
memorize the small set of 6 or so falsy values, because there are many more truthy values, when you see anything that is not a falsy value, you can safely assume it's a truthy value
----------------
resources:
https://developer.mozilla.org/en-US/d...
http://addyosmani.com/blog/exploring-...
http://adripofjavascript.com/blog/dri...
http://stackoverflow.com/questions/19...
http://addyosmani.com/blog/exploring-...
http://stackoverflow.com/questions/21...
• What is JSON? Introduction (Part 1/4)
-----------------------------------------------------------
http://atechapart.com | / alvinsanchez
see my codepens @ http://codepen.io/_asanchez/
On this page of the site you can watch the video online Javascript - How To Pass An Object As a Parameter To a Function with a duration of hours minute second in good quality, which was uploaded by the user A Tech Apart 09 April 2015, share the link with friends and acquaintances, this video has already been watched 3,921 times on youtube and it was liked by 16 viewers. Enjoy your viewing!