title: AngularJS 1.3 - Datepicker initial format is incorrect
body: <p>I started using AngularJS 1.3 yesterday and one problem I have found is that the initial date in the Datepicker is not in the defined format. The format of the date is correct <em>after</em> choosing a date.</p>
  
  <p>The initial format is correct with AngularJS 1.2.10 as can be seen in the example by commenting out the script tag.</p>
  
  <p>How can I set the initial format to be correct?</p>
  
  <p><a href="http://plnkr.co/edit/lPmgnz5hqzsV1HiTlX9Z?p=preview">Plunker example</a></p>
  
  <p>HTML</p>
  
  <pre><code>&lt;!doctype html&gt;
  &lt;html ng-app="plunker"&gt;
    &lt;head&gt;
      &lt;script src="//ajax.googleapis.com/ajax/libs/angularjs/1.3.0-rc.0/angular.min.js"&gt;&lt;/script&gt;
      &lt;!-- &lt;script src="//ajax.googleapis.com/ajax/libs/angularjs/1.2.10/angular.js"&gt;&lt;/script&gt; --&gt;
      &lt;script src="//angular-ui.github.io/bootstrap/ui-bootstrap-tpls-0.11.0.js"&gt;&lt;/script&gt;
      &lt;script src="example.js"&gt;&lt;/script&gt;
      &lt;link href="//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css" rel="stylesheet"&gt;
    &lt;/head&gt;
    &lt;body&gt;
  
    &lt;br&gt;
    &lt;br&gt;
    &lt;div ng-controller="DatepickerDemoCtrl"&gt;
      &lt;div class="row"&gt;
          &lt;div class="col-md-6"&gt;
              &lt;p class="input-group"&gt;
                &lt;input type="text" class="form-control" datepicker-popup="{{format}}" ng-model="dt" is-open="opened" min-date="minDate" max-date="'2015-06-22'" datepicker-options="dateOptions" date-disabled="disabled(date, mode)" ng-required="true" close-text="Close" /&gt;
                &lt;span class="input-group-btn"&gt;
                  &lt;button type="button" class="btn btn-default" ng-click="open($event)"&gt;&lt;i class="glyphicon glyphicon-calendar"&gt;&lt;/i&gt;&lt;/button&gt;
                &lt;/span&gt;
              &lt;/p&gt;
          &lt;/div&gt;
      &lt;/div&gt;
    &lt;/div&gt;
    &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>JS</p>
  
  <pre><code>var app = angular.module('plunker', ['ui.bootstrap']);
  app.controller("DatepickerDemoCtrl", function ($scope) {
    $scope.format = 'dd-MMMM-yyyy';
  
    $scope.today = function() {
      $scope.dt = new Date();
    };
    $scope.today();
  
    $scope.open = function($event) {
      $event.preventDefault();
      $event.stopPropagation();
  
      $scope.opened = true;
    };
  });
  </code></pre>