74 Commits

Author SHA1 Message Date
Jeff Williams
41d33e8399 fix multiple naming issues with members of a class that is the default export (#1120) 2015-12-07 15:56:07 -08:00
Jeff Williams
1bdcc52156 correctly handle classes that are the default export (#1113) 2015-12-03 06:03:20 -08:00
Jeff Williams
224e796428 prevent crash when exporting an anonymous class (#1113) 2015-11-29 14:53:55 -08:00
Jeff Williams
ba673ff4c1 cleanup 2015-11-25 16:03:45 -08:00
Tim Schaub
621f012211 Remove Rhino support 2015-10-30 13:11:43 -06:00
Jeff Williams
5a58bdf5a5 support arrow function expressions (#555) 2015-08-20 11:01:08 -07:00
Jeff Williams
4822bca6c1 whitespace 2015-08-19 09:50:46 -07:00
Jeff Williams
087f07dcd5 use the correct longname for properties documented in instance methods (#1011)
Fixes a regression caused by 65f307322ac64d965694dca8f82bf98f08a1e2e4.
2015-08-18 15:34:24 -07:00
Jeff Williams
8e47e5912a add JSX support (#1001) 2015-08-13 16:48:17 -07:00
Jeff Williams
7a0ec07521 attach comments to default/rest parameters (#1025) 2015-06-21 10:56:34 -07:00
Jeff Williams
01df038474 unconditionally add the necessary properties to AST nodes (#976)
Fixes a bizarre bug that caused us to assign the wrong name to object properties, apparently because the node ID was not defined at the appropriate time.
2015-06-08 15:24:55 -07:00
Jeff Williams
fe9407cd71 support class expressions (#555) 2015-04-10 16:02:27 -07:00
Jeff Williams
80c2a9a38c fix crash when multiple params have inline JSDoc comments with no JSDoc tags (#972) 2015-03-30 09:56:32 -07:00
Jeff Williams
4b8504cac9 support ES 2015 classes (#555, #769)
Incorporates work by @eventualbuddha.
2015-03-18 17:14:04 -07:00
Jeff Williams
67244c06eb quote unsafe property names (#950)
Fixes a regression introduced by the parser overhaul in 44d9ec6831e498bd082de98a5bc60abfdba2bb7f.
2015-03-13 16:56:32 -07:00
Jeff Williams
878115e1c1 autodetect string, boolean, and numeric default values of parameters (#555)
We ignore other types based on these assumptions:

1) It doesn't make sense to show variable identifiers, which may refer to (for example) module-private values that should not be documented.
2) If we tried to capture objects and arrays, we would have to iterate over them to see if they contain any variable identifiers, which would be a pain (and potentially confusing: "Why do some objects appear in the docs but not others?")
3) Most developers will not define complex default values in a function definition.
4) In many cases, object and array default values will be `{}` and `[]`, respectively, and usually those don't merit documentation.
2015-03-03 17:22:30 -08:00
Jeff Williams
1c754e98f2 fix build breakage on Rhino parser 2015-02-27 16:08:55 -08:00
Jeff Williams
96c8f6994d handle ES 2015 rest parameters (#555)
As part of this commit, we automatically flag rest parameters as repeatable, even if the JSDoc comment doesn't identify the parameter as repeatable. As a result, it's difficult to document a rest parameter as though it were a normal parameter (should you want to do that for some reason). I may revert this piece if it generates complaints.
2015-02-27 14:39:20 -08:00
Jeff Williams
65f307322a resolve this correctly in chained class declarations within modules (#894) 2015-02-23 16:58:33 -08:00
Jeff Williams
ae94af0cd8 turn env global into a module, and use the module instead of the global (#812)
The `env` global remains available, since templates and plugins may rely upon it, but it's deprecated as of JSDoc 3.4.0.
2015-02-17 19:07:10 -08:00
Jeff Williams
62f563d730 automatically treat const declarations as constants (#555) 2015-01-30 07:58:36 -08:00
Jeff Williams
e0ec38047b correctly augment the inheritors of virtual doclets (#893) 2015-01-26 16:25:47 -08:00
Jeff Williams
8ad4b49b3f correctly handle symbols named prototype (#891) 2015-01-24 09:09:31 -08:00
Jeff Williams
17c58d76e5 clean up fixtures; add some missing tests 2015-01-24 08:50:09 -08:00
Jeff Williams
e89ecd615f resolve this for computed properties (#890) 2015-01-24 08:40:55 -08:00
Jeff Williams
c61b9307b4 set the correct longname on prototype members whose names are quoted (#888) 2015-01-24 07:40:47 -08:00
Jeff Williams
6faad35eb5 strip enclosing parens from the variation tag's value (#850) 2014-12-25 17:16:59 -08:00
Jeff Williams
416b42fa75 update ESLint; delint 2014-12-13 09:39:21 -08:00
Jeff Williams
5fa636ab7b create doclets for mixed-in symbols (#378)
Also includes a fair amount of cleanup.
2014-12-07 11:05:56 -08:00
Jeff Williams
42104c82ee enable lint-checking for tests; delint/cleanup tests 2014-11-28 18:36:04 -08:00
Jeff Williams
1774569850 delint 2014-10-10 15:19:52 -07:00
Jeff Williams
c083ab7bd1 remove unused test; cleanup 2014-10-07 08:54:22 -07:00
Jeff Williams
413c7eb186 whitespace 2014-10-07 08:53:48 -07:00
Jeff Williams
3b865dde3f Merge remote-tracking branch 'brjs/fix-classdesc-in-modules' 2014-10-07 08:45:24 -07:00
Jeff Williams
4eb86a13a2 handle object literals whose property names must be escaped in a regexp (#775) 2014-10-05 21:35:45 -07:00
Jeff Williams
765abd9a10 cleanup 2014-10-05 21:31:24 -07:00
Dominic Chambers
f2f8d74d22 Added failing test that should work (it works within the template) and
which otherwise explains how the class information is available for use
within module documentation pages.
2014-08-19 17:41:56 +01:00
Dominic Chambers
28cb42de33 Added missing coverage around modules that contain a default CommonJs
class being exported within the module -- this has actually shown that
the doclets produced are probably correct, and that the bug is likely to
be within the template.
2014-08-19 16:53:58 +01:00
Jeff Williams
89237260c6 support virtual comments for overloaded symbols (#727) 2014-08-12 09:37:00 -07:00
Jeff Williams
abfa24578c don't log an error when a comment only contains whitespace (#698) 2014-07-02 20:11:39 -07:00
Jeff Williams
254c05fbf6 set the appropriate longname for function declarations in AMD modules (#685)
This is a hack. See #693 for details.
2014-06-29 17:11:55 -07:00
Jeff Williams
1566421a62 give doclets a longname even if the name is empty (#643) 2014-04-26 10:57:10 -07:00
Jeff Williams
f635b10b6f fix comment-attachment issue (#638)
The issue in brief: Within an object literal, if a standalone comment was followed by a commented symbol, the symbol's comment would not be attached correctly.

The fix essentially reverts the changes for #565, which are no longer needed thanks to 50cd99fa2fca753fcf7c9ec3ecf70afd47168e94.

The fix also corrects the order in which we walk a MemberExpression's child nodes. Without this correction, comments would not be attached correctly inside CallExpression nodes.
2014-04-25 21:53:30 -07:00
Jeff Williams
3e4e48accd attach inline type annotations to function params (#611)
includes a new Rhino jar: jsdoc3/rhino@bb2446ad
2014-03-30 22:01:04 -07:00
Jeff Williams
3b5db81d92 fix closures with multiple lends tags (#569)
There were three separate problems here:

1. The visitor called `trackVars` at the wrong time for `AssignmentExpression` and `VariableDeclarator` nodes, which prevented JSDoc from setting the `funcscope` property correctly.
2. The `funcscope` property was being added to `VariableDeclarator` nodes. It should only be added to `AssignmentExpression` nodes.
3. We were trying to resolve the variable name `____` in `AssignmentExpression` nodes. This is a special value we add to the source code so that the `lends` tag will work, and it should never be resolved against the enclosing scope.

The previous, buggy behavior looked reasonable in most cases, but it didn't work for closures that contain multiple `lends` tags.
2014-03-16 19:58:34 -07:00
Jeff Williams
48e6c392d5 huge whitespace cleanup
- remove all trailing whitespace
- for consistency, replace all tabs with spaces
2014-03-03 07:43:01 -08:00
Jeff Williams
4e3e4a0151 fix lends tag inside nested function calls (#565)
plus some minor test cleanup
2014-02-23 20:16:16 -08:00
Jeff Williams
ec93145550 fix the lends tag inside of closures (#573) 2014-02-23 09:36:59 -08:00
Jeff Williams
34d98ed438 add @also to tag definitions (#574)
This tag is used internally. It previously caused
"not a known tag" errors when
tags.allowUnknownTags was set to false.
2014-02-16 08:39:32 -08:00
Jeff Williams
43b6920085 document new properties on module.exports (#500) 2014-02-01 20:12:24 -08:00