Having an issue with the search functionality on my website. I am using a ng-init function called getAllStudents to fetch all student data from the database. Later, I am trying to limit the display to only 10 students in the ng-repeat directive. However, when a user searches for a specific student, it should search through all the students fetched by getAllStudents and display them. Currently, this is not working due to the use of limitTo. Can someone please provide some assistance?
<main ng-init="getAllStudents()">
<section ng-repeat="student in getAllStudents() | limitTo: 10 | filter: searchText>
<div ng-click="showStudent(student.details.id, showStudent.details.name)"></div>
</section>
</main>