Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

object destructuring default value

let a, b;

[a=5, b=7] = [1];
console.log(a); // 1
console.log(b); // 7
Source by developer.mozilla.org #
 
PREVIOUS NEXT
Tagged: #object #destructuring #default
ADD COMMENT
Topic
Name
6+8 =