Skip to content

Commit

Permalink
adding angular array syntax for minification support
Browse files Browse the repository at this point in the history
  • Loading branch information
alexreardon committed Apr 23, 2014
1 parent dc50ae5 commit a963a5a
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions angular-picturefill.js
Original file line number Diff line number Diff line change
@@ -1,28 +1,28 @@
'use strict';

angular.module('ng.picturefill', [])
.directive('pictureFill', function () {
.directive('pictureFill', [function () {
return {
controller: 'PictureFillCtrl',
link: function (scope, elem, attrs) {
elem.attr('data-picture', '');
}
};
})
}])
.directive('pfSrc', function () {
return {
link: function (scope, elem, attrs) {
elem.attr('data-src', attrs.pfSrc);
}
};
})
.controller('PictureFillCtrl', function ($timeout) {
.controller('PictureFillCtrl', ['$timeout', function ($timeout) {
$timeout(picturefill);
})
.filter('trimExt', function () {
}])
.filter('trimExt', [function () {
return function (text) {
if (text) {
return text.slice(0, text.lastIndexOf('.')) || text;
}
};
});
}]);

0 comments on commit a963a5a

Please sign in to comment.