1var book = {}
2
3Object.defineProperties(book,{
4 key1: { value: "it", enumerable: true },
5 key2: {
6 enumerable: true,
7 get: function(){
8 return this.key1 + " works!";
9 }
10 }
11});
12
13console.log(book.key2); //prints "it works!"
14