Skip to content

Instantly share code, notes, and snippets.

@jorgepinon
Created July 23, 2016 02:27
Show Gist options
  • Save jorgepinon/ed1d4ae2a6bcc4c8199343c60e21112a to your computer and use it in GitHub Desktop.
Save jorgepinon/ed1d4ae2a6bcc4c8199343c60e21112a to your computer and use it in GitHub Desktop.
var myModule = (function () {
var privateMethod = function () {
console.log('A private method');
},
someMethod = function () {
console.log('A public method');
},
anotherMethod = function () {
console.log('Another public method');
};
return {
someMethod: someMethod,
anotherMethod: anotherMethod
};
}());
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment