jsdoc / jsdoc/jsdoc

Class Fields Inline Documentation

Open
#1,842 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
15.5k
Forks
1.5k
Avg merge
10d 23h
Merged PRs (30d)
1

Description

Instead of requiring @property tags to be explicitly specified in a comment, jsdoc should support inline definitions when properties are explicitly declared in the class body (a relatively new JS feature). Ideally it should automatically parse the variable name and default value as well, with an optional syntax for specifying type. This would be equivalent to similar syntax supported by Doxygen.

See below for an example.

Input code
/** foo class */
class foo {
   bar = 0; /**< Variable bar */
   list = []; /**< {Array} An amazing list */
   // ....
}

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No file or test is named. Start by locating the existing @property parsing and class-field handling, then review the example syntax and decide how names, defaults, and optional types should be represented. Done means declared class properties are documented without explicit @property tags and the behavior is covered by tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
documentation
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.