Jul 22, 2017 · 1 min read
hey, dave! Yes, it was a format problem on the code. The continuation of the code was in the other line. I formatted better. So we have:
const objTarget = {};
const objSource = {
set greet(name) { console.log('hey, ' + name); }
};
Object.defineProperties(objTarget,
Object.getOwnPropertyDescriptors(objSource));objTarget.greet = 'love';
Tks for the observation ;)