Created
April 3, 2018 19:05
-
-
Save LearningMaterial/5579f625d8b3b90e8955ea90d288f620 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
var JS = { | |
name: "The Javascript language", | |
log() { | |
this.name = "updated Javascript Language"; | |
console.log(this); | |
var setName = newName => { | |
// this points to JS object | |
this.name = newName; | |
}; | |
setName("Updated Again, The Javascript language"); | |
console.log(this); | |
} | |
}; | |
JS.log(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment