angularjs - Angular orderBy evaluate expression -
i orderby evaluate expression
currently have:
ng_repeat: "post in posts | orderby:"up_votes"
i instead order {{up_votes - down_votes}}
ng_repeat: "post in posts | orderby:'down_votes - up_votes'"
just use single quotes wrap expression orderby
or add votediff function controller , orderby:votediff
Comments
Post a Comment