Optional Function Arguments


/ Published in: JavaScript
Save to your folder(s)

Simple way of allowing functions to take optional arguments. Always place the optional arguments last, so you don't have to explicitly pass an argument as "undefined".

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.