I am in need of assistance with AngularJS. How can I re-initialize a variable in scope after using emit? Here is an example code snippet:
$scope.uiConfig = {title: "example"};
$scope.$emit('myCustomCalendar', 'Data to send');
$scope.$on('myCustomCalendar', function () {
$scope.uiConfig = {title: "new Title"};
});