-
Notifications
You must be signed in to change notification settings - Fork 12.9k
Closed
Labels
BugA bug in TypeScriptA bug in TypeScriptDomain: JSDocRelates to JSDoc parsing and type generationRelates to JSDoc parsing and type generationDomain: Quick Infoe.g. hover text, tool-tips, and tooltips.e.g. hover text, tool-tips, and tooltips.Help WantedYou can do thisYou can do this
Milestone
Description
Bug Report
π Search Terms
jsdoc extended generic class documentation
π Version & Regression Information
- This changed between versions
4.6.4
and4.7.4
β― Playground Link
π» Code
/** @template T */
class GenericBaseClass {
/** Method documentation. */
method() {}
}
/** @extends {GenericBaseClass<number>} */
class GenericExtendedClass extends GenericBaseClass {
// hover over 'method' to see the documentation
method() {}
}
const y = new GenericExtendedClass();
// hover over 'method' to see the documentation
y.method;
π Actual behavior
When hovering over y.method
or the method()
implementation from GenericExtendedClass
the documentation of the method is missing.
π Expected behavior
Hovering reveals the inherited documentation from the parent class. This used to work in TypeScript 4.6.4
and still works when using TypeScript, where Generic classes are extended using GenericBaseClass<number>
syntax. Only in JavaScript, where @extends {GenericBaseClass<number>}
is used, will the documentation disappear. When extending classes that don't have any generic parameters this also still works fine.
ozyx and RythenGlyth
Metadata
Metadata
Assignees
Labels
BugA bug in TypeScriptA bug in TypeScriptDomain: JSDocRelates to JSDoc parsing and type generationRelates to JSDoc parsing and type generationDomain: Quick Infoe.g. hover text, tool-tips, and tooltips.e.g. hover text, tool-tips, and tooltips.Help WantedYou can do thisYou can do this