search

Home  >  Q&A  >  body text

angular.js - angular for loop output label

How to use angular to dynamically output $scope.total number of tags.
When $scope.total = 10, there are 10 p tags
When $scope.total = 20, there are 20 p tags

阿神阿神2793 days ago639

reply all(3)I'll reply

  • 某草草

    某草草2017-05-15 16:58:08

    You can refer to this question and generate an array yourself for ng-repeat to use

    reply
    0
  • 曾经蜡笔没有小新

    曾经蜡笔没有小新2017-05-15 16:58:08

    <p ng-repeat="item in total"></p>
    Isn’t this just a p in total

    reply
    0
  • 天蓬老师

    天蓬老师2017-05-15 16:58:08

    angular provides ng-repeat, just use it directly

    reply
    0
  • Cancelreply