Skip to content

Markdown code blocks in JSDoc result in being prefixed with * in hover popups when inspected #61680

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
KrofDrakula opened this issue Oct 24, 2018 · 1 comment
Assignees
Labels
javascript JavaScript support issues upstream Issue identified as 'upstream' component related (exists outside of VS Code)

Comments

@KrofDrakula
Copy link

Possibly related issue: #43783

This issue relates to the indentation and content of code blocks in JSDoc comments using Markdown formatting for code blocks in the body of a description for any type, interface or function.

Version: 1.28.2 (user setup)
Commit: 7f3ce96
Date: 2018-10-17T00:23:51.859Z
Electron: 2.0.9
Chrome: 61.0.3163.100
Node.js: 8.9.3
V8: 6.1.534.41
Architecture: x64

Steps to Reproduce:

  1. Write the following annotation in a TypeScript file:
/**
 * This function just works.
 * 
 * Example:
 * 
 * ```js
 * myFn('hello');
 * ```
 */
type Fn = (arg: any) => void;
  1. Hover over the Fn type name to get the JSDoc hover popup:

image

  1. Notice that the code block is prefixed with * for every line of code.

Per JSDoc, all the lines should have the indentation and * stripped from content before passing it to the Markdown processor. This would align the tool with all other documentation tools and would avoid showing the * characters preceding every JSDoc code block line.

Does this issue occur when all extensions are disabled?: Yes

@vscodebot vscodebot bot added the javascript JavaScript support issues label Oct 24, 2018
@mjbvz
Copy link
Collaborator

mjbvz commented Oct 24, 2018

Thanks. Already tracked upstream by microsoft/TypeScript#23517

@mjbvz mjbvz closed this as completed Oct 24, 2018
@mjbvz mjbvz added the upstream Issue identified as 'upstream' component related (exists outside of VS Code) label Oct 24, 2018
@vscodebot vscodebot bot locked and limited conversation to collaborators Dec 10, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
javascript JavaScript support issues upstream Issue identified as 'upstream' component related (exists outside of VS Code)
Projects
None yet
Development

No branches or pull requests

2 participants