-
Notifications
You must be signed in to change notification settings - Fork 12.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support property declarations in jsdoc template generation (#36658)
* Support property declarations in jsdoc template generation * fix lint and add test
- Loading branch information
Showing
2 changed files
with
44 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
39 changes: 39 additions & 0 deletions
39
tests/cases/fourslash/docCommentTemplateClassDeclProperty01.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
/// <reference path='fourslash.ts' /> | ||
|
||
const singleLineOffset = 3; | ||
const multiLineOffset = 12; | ||
|
||
|
||
////class C { | ||
//// /** /*0*/ */ | ||
//// foo = (p0) => { | ||
//// return p0; | ||
//// }; | ||
//// /*1*/ | ||
//// bar = (p1) => { | ||
//// return p1; | ||
//// } | ||
//// /*2*/ | ||
//// baz = function (p2, p3) { | ||
//// return p2; | ||
//// } | ||
////} | ||
|
||
verify.docCommentTemplateAt("0", multiLineOffset, | ||
`/** | ||
* | ||
* @param p0 | ||
*/`); | ||
verify.docCommentTemplateAt("1", multiLineOffset, | ||
`/** | ||
* | ||
* @param p1 | ||
*/`); | ||
verify.docCommentTemplateAt("2", multiLineOffset, | ||
`/** | ||
* | ||
* @param p2 | ||
* @param p3 | ||
*/`); | ||
|
||
|