title: Declaring variables without a value
body: <p>I wish to create a Javascript object with nested variables where some of the variables will not have a default value specified.</p>
  
  <p>I currently have this:</p>
  
  <pre><code>var globalVarA = "foo";
  var globalVarB = "bar";
  var globalVarC;
  
  function myFunction(){
    //do something
  }
  </code></pre>
  
  <p>I wish to change this to:</p>
  
  <pre><code>var myObject = {
    GlobalVars: {
       globalVarA: "foo",
       globalVarB: "bar",
       globalVarC
    },
    myFunction: function(){
       //do something
    }
  }
  </code></pre>
  
  <p>However I get the following error:</p>
  
  <blockquote>
    <p>Expected ':'</p>
  </blockquote>
  
  <p>How can I declare this variable without a value?</p>
  
  <p>Is this the best practice or is there an alternative better solution?</p>