title: converting date format in angularjs controller
body: <p>i write the following coding to print the current date time</p>
  
  <p><code>$scope.date = new Date();</code></p>
  
  <p>and then i print the same using consol.log</p>
  
  <pre><code>console.log($scope.date);
  </code></pre>
  
  <p>and it is working fine</p>
  
  <blockquote>
    <p>Tue Jan 24 2017 16:36:06 GMT+0530 (India Standard Time)</p>
  </blockquote>
  
  <p>but now i want to change the date format and i want to print like</p>
  
  <blockquote>
    <p>21-12-2016</p>
  </blockquote>
  
  <p>can anybody help me here?</p>
  
  <p>i used the conversion but i am unable to remember the page or the url of the page right now,</p>
  
  <p>and stuck on this,</p>
  
  <p>before i leave for the home today i thought of solving this issue</p>