Even though only the most relevant methods are listed on this page, the full EventEmitter2 API is available on the
grunt.event object. Event namespaces may be specified with the
. (dot) separator, and namespace wildcards have been enabled.
Note that Grunt doesn't yet emit any events, but can still be useful in your own tasks.
Adds a listener to the end of the listeners array for the specified event.
Adds a one time listener for the event. The listener is invoked only the first time the event is fired, after which it is removed.
Adds a listener that will execute n times for the event before being removed.
grunt.event.many(event, timesToListen, listener)
Remove a listener from the listener array for the specified event.
Removes all listeners, or those of the specified event.
Execute each of the listeners that may be listening for the specified event name in order with the list of arguments.
grunt.event.emit(event, [arg1], [arg2], [...])