求大神解释
var person = {}; Object.defineProperties(person,{ title : {value : 'fe'}, crop : {value : 'BABA'}, salary : {value : 5000}, luck : { get : function () { return Math.random() > 0.5 ? 'good' : 'bad'; } }, promote : { set : function(level) { this.salary *= level; } } }); // var obj = Object.getOwnPropertyDescriptor(person,'luck'); // console.log(obj); // console.log(person.salary); person.promote = 2; console.log(person.salary)