title: Passing arguments into the revealing Module pattern in Javascript
body: <p>How can you pass arguments to a function when implementing the Revealing module pattern in JavaScript. I have a module like this</p>
  
  <pre><code>var GlobalModule = (function() {
      function consoleLog(textToOutput) {
          console.log(textToOutput);
      }
  
      return {
          consoleLog: consoleLog()
      };
  })();
  </code></pre>
  
  <p>Later on, when i run <code>GlobalModule.consoleLog("Dummy text");</code>, I get <code>undefined</code> as the output.</p>