I have a dynamic data to display in front end.I have 'see more' and 'see less' option to each data.When Clicking the 'see more' option need to call some api. So I need to avoid 'see more' click. if i have five records and calling see more option using javascript element click()
method in angular. this is not working for html collection.
setTimeout(() => {
let getSeeMoreEle = document.getElementsByClassName('see-more');
for (let index = 0; index < getSeeMoreEle.length; index++) {
getSeeMoreEle[index].click();
}
}, 500);