title: AngularJS input not updating with ng-model
body: <p>I have a form with three input fields:</p>
  
  <pre><code>&lt;form name="myForm" novalidate ng-controller="MainController as vm"&gt;
      &lt;div&gt;
          &lt;input type="text" ng-model="vm.id" name="idInput" required&gt;
          &lt;input type="email" ng-model="vm.email" name="emailInput" required&gt;
          &lt;input type="text" ng-model="vm.output" name="output"&gt;
      &lt;/div&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p><code>vm.output</code> is a variable defined in my controller that contains some strings plus <code>vm.id</code> and <code>vm.email</code>:</p>
  
  <pre><code>vm.output = 'myurl.com?id=' + vm.id + '&amp;email=' + vm.email;
  </code></pre>
  
  <p>I want to generate an output URL based on the user input in the id and email fields. However, the output-field does not update when I enter some input into the two other fields. It just says <code>myurl.com?id=undefined&amp;email=undefined</code>,</p>
  
  <p>I can get it working if I use</p>
  
  <p><code>ng-value="'myurl.com?id=' + vm.id + '&amp;email=' + vm.email"</code></p>
  
  <p>However, I'm using <a href="https://github.com/asafdav/ng-clip" rel="nofollow">ng-clip</a> which gets the content to copy by using ng-model so I need to use that.</p>
  
  <p>Also, here's my controller:</p>
  
  <pre><code>angular
      .module("app")
      .controller("MainController",[MainController);
  
  function MainController(){
      var vm = this;
  
      vm.output = 'myurl.com?id=' + vm.id + '&amp;email=' + vm.email;
  }
  </code></pre>
  
  <p>Any suggestions?</p>