how to scroll the scroll bar to the specified content by default after using ng-reapeat to generate content.
html part of the code is
<div class="scrollHorizontal">
<div class="cebTitleScroll identityItem" v-class="{"ceb_border_Pop":($index==defaultIdentity)}"
v-repeat="item in visaInfo.identity" v-click="chooseIdentity($index)">{{item.identityTitle}}
</div>
</div>
data is mounted in init. Using js native or jq operation scroll bar has the problem that dom is not generated and cannot be operated.
// var identityDomChoose = document.getElementsByClassName("identityItem");
// console.log(identityDomChoose);
if you do this, identityDomChoose is normal and there is data inside HTMLCollection, but my identityDomChoose.item (x) or identityDomChoose [x] will undefind
how to scroll the content automatically so that it can achieve the following effect: