You can document this behavior by documenting your events ( event1 , event2 , ...) as @event MyFunc#event1 and MyFunc, or whoever @fires MyFunc#event1 , with @fires MyFunc#event1 .
You can also document the functions that listen to these events using @listens MyFunc#event:event1 .
Here are the official JSDoc pages for the above tags:
Pay attention to some nuance around the "event" mentioned on the tag event page, repeating here:
JSDoc automatically adds event: namespaces to each event name. In general, you should include this namespace when referencing an event in another report. (The @fires tag is a notable exception; it allows you to skip the namespace.)
source share