What is the right to add new content to $scope.myList = [] when I want to manipulate the DOM?
I tried $scope.myList.push(data); , which adds new data to the end and therefore to the end of the HTML template inside the ng repeater. I want him upstairs. The unshift function will reorder the array and update all elements.
New in angular.
EDIT: Perhaps the question should be this: how to add dynamic content to the top of my template?
source share