AngularJS ng-repeat handle empty list case

后端 未结 10 2275
隐瞒了意图╮
隐瞒了意图╮ 2020-11-30 16:47

I thought this would be a very common thing, but I couldn\'t find how to handle it in AngularJS. Let\'s say I have a list of events and want to output them with AngularJS, t

10条回答
  •  一向
    一向 (楼主)
    2020-11-30 17:19

    You can use this ng-switch:

    'Found '{{(friends | filter:searchText).length}} friends

    No friends
    Name Phone
    {{friend.name}} {{friend.phone}}

提交回复
热议问题