I'm playing around with AngularJS (and trying to get my head round it) and have a controller which for the purpose of this question can be simplified to:
$scope.addMessage = function() {
$scope.messages.push({author: 'nick',
text: $scope.messageText, active: true});
};
Every time that the model changes due to this '$scope.addMessage' I want to run emojify.run();... If I simply put it after $scope.messages.push... it runs before the data is shown in the view and therefore doesn't work. How do I call the function emojify.run(); once the view has updated?