title: JavaScript: Access object multi-level property using variable
body: <p>How can I access a multi-level property if I am using a variable as the key?</p>
  
  <p>This is not working:</p>
  
  <pre><code>var obj = {
      first: {thirst: "yo"},
      second: {beckon: "dud"}
  }
  var key = "first.thirst";
  var result = obj[key];
  </code></pre>