title: Passing onchange event in object notation
body: <p>I have a simple code, which goes with a more complex code though I will only be showing the snippet in the object notation.</p>
  
  <pre><code>var test = {
      add: {
          select: function(options){
              console.log(options.id);
              console.log(options.className);
              onchange: function(){
               //code here
              } 
          }
      }
  }
  </code></pre>
  
  <p>That is the code above, as I've tried many instances to make this work firing Vanilla JS or even jQuery to make it fire. The code to make it work would look like this-</p>
  
  <pre><code>test.add.select({
      id:'id',
      className: 'class',
      onchange: function(){
          if(key===0){
              console.log('0');
          }else if(key===1){
              console.log('0');
          }else if(key===2){
              console.log('0');
          }
      }
  });
  </code></pre>
  
  <p>Key is being set as the actual select menu key. Please see the JSBIN for a much better visual.</p>
  
  <p><a href="http://jsbin.com/amonid/1/edit" rel="nofollow">http://jsbin.com/amonid/1/edit</a></p>
  
  <p>Basically when the select is change for now console.logging is what I am doing, later on I will change it for the needs I have. Can someone explain to me how I would go about adding this all?</p>