dartdoc icon indicating copy to clipboard operation
dartdoc copied to clipboard

Constructor documentation should describe arguments better

Open Hixie opened this issue 8 years ago • 1 comments

Constructors often use the "this.foo" syntax for their arguments. We should take advantage of this in the following ways:

  • [ ] When showing the constructor page, inline the description of the "foo" field next to the "this.foo" argument.
  • [ ] Hyperlink from the constructor to the field. (https://github.com/dart-lang/dartdoc/issues/1958)

Hixie avatar Aug 08 '16 22:08 Hixie

Bonus points if you also detect cases of arguments named X that are assigned to a field named _X using an initializer, where the field also happens to be the return value of a getter named X.

Hixie avatar Aug 08 '16 22:08 Hixie