$emit(name, args);
Dispatches an event name
upwards through the scope hierarchy notifying the registered $rootScope.Scope
listeners.
The event life cycle starts at the scope on which $emit
was called. All listeners listening for name
event on this scope get notified. Afterwards, the event traverses upwards toward the root scope and calls all registered listeners along the way. The event will stop propagating if one of the listeners cancels it.
Any exception emitted from the listeners will be passed onto the $exceptionHandler service.
Parameters
Param | Type | Details |
---|---|---|
name | string | Event name to emit. |
args | * | Optional one or more arguments which will be passed onto the event listeners. |
Returns
Object |
Event object (see |
Please login to continue.