I want to use delay in my angular.foreach
loop. I have a list and I want to display them one by one with 2 seconds periods.
angular.forEach(vm.SimulationResult, function (value, key) {
timeout2 = $timeout(function () {
vm.Alerts.push({ msg: value.MainStatus });
}, 2000);
});
what should I do ?