title: Angular 5 - "Cannot read property of undefined"
body: <p>In Angular 5, for input</p>
  
  <pre class="lang-html prettyprint-override"><code>&lt;input name="techSpecMeta.make" [(ngModel)]="techSpecMeta.make" type="text" class="form-control border-input" placeholder="Enter car brand"&gt;
  </code></pre>
  
  <p>getting error
  Cannot read property 'make' of undefined
      at Object.eval [as updateDirectives]</p>
  
  <pre class="lang-js prettyprint-override"><code>export class UserComponent implements OnInit {
    constructor(private vahinfo: VehicleInfo) {}
    ngOnInit() {}
    techSpecMeta: {};
    onSave = function(vehicle, isValid: boolean) {
      this.vahinfo.saveVehicle(vehicle).subscribe(data =&gt; {
        console.log(data.data)
      }, error =&gt; this.errorMessage = error)
    }
  }
  </code></pre>