Synonyms
emits
语法
🌐 Syntax
@fires <className>#[event:]<eventName>
概述
🌐 Overview
@fires 标签表示当方法被调用时,它可以触发指定类型的事件。使用 @事件 标签 来记录事件的内容。
🌐 The @fires tag indicates that a method can fire a specified type of event when it is called. Use the @event tag to document the event's content.
示例
🌐 Examples
/**
* Drink the milkshake.
*
* @fires Milkshake#drain
*/
Milkshake.prototype.drink = function() {
// ...
};