Created
September 16, 2014 03:30
-
-
Save hawkrives/060e472dc0899e2ee555 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| console.log('obj 1'); | |
| var obj = { | |
| data: 0, | |
| get x() { | |
| return this.data + 1; | |
| } | |
| } | |
| console.log(obj.x); | |
| //// | |
| console.log('obj 2'); | |
| var obj2 = { | |
| data: 0, | |
| get x() { | |
| return -this.data; | |
| }, | |
| set x(val) { | |
| this.data = val; | |
| } | |
| } | |
| obj2.x = 5; | |
| console.log(obj2.x); | |
| //// | |
| console.log('obj 3'); | |
| var obj3 = { | |
| data: 0, | |
| get x() { | |
| return this.data += 1; | |
| }, | |
| set x(val) { | |
| this.data = val; | |
| } | |
| } | |
| console.log(obj3.x); | |
| //// | |
| console.log('obj 4'); | |
| var obj4 = { | |
| data: 0, | |
| get x() { | |
| return this.data += 1; | |
| }, | |
| set x(val) { | |
| this.data = val; | |
| } | |
| } | |
| obj4.x; | |
| console.log(obj4.x += 5); | |
| console.log(obj4.x); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
After finishing an interesting book, I was craving a virtual evening activity with a minimal investment. I thought I'd find informative platforms offering low-cost income, so I could experiment without rushing. I discovered a site, https://casino-hex.it/, which aggregates data on Italian alternatives. This address offers comprehensive descriptions of offers, such as reload bonuses every Friday with extra funds, free spins on live roulette, 5% daily cashback, VIP systems with personalized gifts, comparisons between desktop and mobile versions, deposit methods with cryptocurrencies like Bitcoin, manuals on terms and conditions, opinions from real players, lists of low-volatility games, updates on special events, and tips for a balanced approach.