AngularJS + jQuery UI Date Picker Plugin
Simple example showing how to spin up the jQuery UI date picker plugin.
HTML
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.0.1/angular.min.js"></script>
<div ng-app="myApp" ng-controller="MyCtrl">
<p>Date: <input type="text" id="datepicker-{{id}}" datepicker></p>
</div>
JavaScript
var module = angular.module('myApp', []);
module.directive('datepicker', function() {
var linker = function(scope, element, attrs) {
element.datepicker();
}
return {
restrict: 'A',
link: linker
}
});
function MyCtrl($scope) {
$scope.id = 7
}