What is the output of the following code snippt? | JavaScript Output Based Question | JavaScript Variable Destructing
@Yomesh Gupta
var person = {};
({
name: person["username"]
} = {
username: "yomeshgupta",
email: "[email protected]",
name: "yomesh",
});
console.log(person.username, person.name);
Option 1
undefined undefined
Option 2
Uncaught SyntaxError
Option 3
yomesh undefined
Option 4
yomeshgupta yomesh