Created
October 1, 2018 09:39
-
-
Save manekinekko/243fd623c58c44cb96745073d5e0f5da 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
function Jedi() { | |
let jedi = ""; | |
this.luke = () => { | |
jedi = "Luke"; | |
return this; | |
} | |
this.imYourFather = () => `${jedi}, Je suis ton père`; | |
} | |
var jedi = new Jedi(); | |
jedi.luke().imYourFather(); // Luke, Je suis ton père |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment