Skip to content

Angular directive? #4

@mmealling

Description

@mmealling

Has anyone gotten this to work with an ng-repeated li in Angular? This is what we tried but no luck:

.directive('ngAlphaListNav', function() {
return {
restrict: 'A',
link: function(scope, element, attrs) {
listnavattr = angular.fromJson(attrs.ngAlphaListNav);
ulid=listnavattr.ulid;
delete listnavattr.ulid;
if (scope.$last){
$("#" + ulid).listnav(listnavattr);
}
}
}
});

And this HTML (Jade):

customlist-nav

ul#customlist
li.item(ng-repeat='foo in foos', id='{{foo.id}}', ng-alpha-list-nav='{ "includeAll": "false", "ulid": "customlist" }')

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions