Angular ng-repeat Error “Duplicates in a repeater are not allowed.”

后端 未结 10 2332
青春惊慌失措
青春惊慌失措 2020-11-22 06:11

I am defining a custom filter like so:

10条回答
  •  情歌与酒
    2020-11-22 06:43

    Duplicates in a repeater are not allowed. Use 'track by' expression to specify unique keys.

    Repeater: {0}, Duplicate key: {1}, Duplicate value: {2}
    

    Example

    
    
    
        
        
        
    
    
    
        
    First Name Last Name
    {{person.firstName}} {{person.lastName}}

    {{person1.firstName}} {{person1.lastName}}
    {{sayHello()}}

提交回复
热议问题