-
-
Notifications
You must be signed in to change notification settings - Fork 169
Open
Labels
Description
Ensure that the following tags are not present except on their given context (with a few only if another tag is present):
- Only on functions or global:
@param,@returns,@async,@generator,@constructs,@fires,@interface,@listens,@this,@yields, and possibly@overridefor some projects - Only on classes or functions:
@class,@classdesc,@constructor,@hideconstructor,@implements(there is a rule for this, but it could be removed in favor of this rule; this one can also be global with@callback/@function) - Only on objects: possibly these if so chosen by a project:
@enum,@event,@mixes,@mixin,@namespace - Only on objects (possibly requiring
@namespace?) or global (if with@typedef):@property - Only with
constkeyword:@constant/@const - Only at global level:
@external(@filetoo but adding with a new proposed rule),@function(don't really need except with interfaces),@callback,@typedef,@author,@module, (@license/@copyrightif project determines so by option) - Not global: All tags besides those in the previous category and, unless accompanied by a
@functionor@callbacktag, the function tags (which can be a part of interface); exceptions might include:@todo,@tutorial,@see,@description
Such a rule which checked all contexts for unexpected tags might also optionally prohibit overly generic tags being used when a more specific tag existed for that context, e.g., @name when @function was possible (or not even needed).
Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.