0

I have a ng-repeat:

<label ng-repeat="atp in Keywords | unique:'atp'">
   {{atp}}
</label>

In atp, I got:

client
animal
zoo
boat

I expect in output:

animal
boat
client
zoo

Thanks for your help!

Jose
  • 1,159
  • 1
  • 9
  • 23
  • `unique` is not an angular built-in filter. If you did add it to your module, please show the code for it, because it could be the cause of the problem (as Jon's answer should actually work). – Yoshi Nov 06 '14 at 11:31

1 Answers1

1

Try this:

<label ng-repeat="atp in Keywords | unique:'atp' | orderBy:atp">
   {{atp}}
</label>
Jon Snow
  • 3,682
  • 4
  • 30
  • 51