In code why following line is used, since it's not creating emails from collection list.
Ambiguous Code Line: "return {$item}$@{ this.domain }
"
var object = {
collection: ["kapil", "abdul", "shiv"],
domain: 'infobeans.com',
method: function method() {
return this.collection.map(item => {
//return item + '@' + this.domain;
return `{$item}$@{ this.domain }`
});
}
};
console.log(object.method());