You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
JSDuck supports the concept of documenting class members not explicitly declared in code. Typically this is used for creating basic entities for upstream libraries.
In general however it uses the rule that a documentation block and code are only associated when directly connected. If there is an empty line between, then it is no longer associated.
So e.g.
/** * Descriptive description of Foo. * * @class Foo *//** * Descriptive description of bar. * * @method bar * @param x */(function($){..}(jQuery));
Would not associate method bar with the closure. And it would not throw a warning about parameter x not matching $, for two reasons:
There is a new line in between.
It is not a plain function declaration or expression assigned to a property in an object literal, or variable assignment. As such, the function seen there is irrelevant.
The same is like this:
/** * @param x */varfoo=(function(y,z){..returnfunction(x){..};}(1,2));
I'm not sure whether this error is a regression, or that it is part of a new rule. But for Wikimedia, jquery.suggestions.js (source code) is causing the following warning:
27 | * @param {Object} options
13:54:14 Expected $ but got options at ./resources/src/jquery/jquery.suggestions.js :
Because it is wrongly associating the block with the closure.
The text was updated successfully, but these errors were encountered:
JSDuck supports the concept of documenting class members not explicitly declared in code. Typically this is used for creating basic entities for upstream libraries.
Examples:
In general however it uses the rule that a documentation block and code are only associated when directly connected. If there is an empty line between, then it is no longer associated.
So e.g.
Would not associate method bar with the closure. And it would not throw a warning about parameter
x
not matching$
, for two reasons:The same is like this:
I'm not sure whether this error is a regression, or that it is part of a new rule. But for Wikimedia, jquery.suggestions.js (source code) is causing the following warning:
Because it is wrongly associating the block with the closure.
The text was updated successfully, but these errors were encountered: