title: Two-way binding nested objects
body: <p>I have the following class in my Angular2 app:</p>
  
  <pre><code>export class MyClass {
    name: Object;
  }
  </code></pre>
  
  <p>The name object has a dynamic property to load the current language. Currently, when I want to do two-way binding, I'm doing like this:</p>
  
  <pre><code>item: MyClass = {
    name: { en: string }
  }
  </code></pre>
  
  <p>That way, in my HTML, I just use <code>[(ngModel)]="item.name.en"</code>. However, I have many other properties in that class as well.</p>
  
  <p>Do I have to define all of them inside <code>item</code>? If I try to call only <code>MyClass</code> (<code>item: MyClass;</code>), I get <code>undefined error</code>.</p>
  
  <p>Is there a better way to do that?</p>