Last active
March 26, 2018 20:30
-
-
Save aryak007/c53704db87c206187303a949ca20f96a to your computer and use it in GitHub Desktop.
This file contains 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 outerFunction = (function(){ | |
var publicInterface = { | |
inner : function(){ | |
console.log("Inner function"); | |
}, | |
anotherInner: function(){ | |
publicInterface.inner(); | |
} | |
}; | |
return publicInterface; | |
})(); | |
outerFunction.anotherInner(); // It will print "Inner function" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment