Skip to content
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

Show extended descriptions in lint popups #3841

Open
Merrit opened this issue Feb 22, 2022 · 1 comment
Open

Show extended descriptions in lint popups #3841

Merrit opened this issue Feb 22, 2022 · 1 comment
Labels
blocked on vs code / lsp / dap Requires a change in VS Code to progress is enhancement
Milestone

Comments

@Merrit
Copy link

Merrit commented Feb 22, 2022

Is your feature request related to a problem? Please describe.
Currently the hover information for lints only shows the short description of lint rules, which often fails to inform the user as to why or what to do instead, meaning you'd have to follow the link to the website if you didn't know already.

Describe the solution you'd like
I think the hover info should include the details of the rule which usually has an extended description and examples.

Additional context

An example of the current implementation, showing the camel_case_types rule:

image

This only includes the _desc property of the rule.

If it included the _details property it would include helpful context, and our lint popup could be more like:

Name types using UpperCamelCase. dart(camel_case_types)

From the style guide:

DO name types using UpperCamelCase.

Classes and typedefs should capitalize the first letter of each word (including
the first word), and use no separators.

GOOD:

class SliderMenu {
  // ...
}

class HttpRequest {
  // ...
}

typedef num Adder(num x, num y);
@DanTup
Copy link
Member

DanTup commented Feb 23, 2022

Unfortunately it's not currently possible to use Markdown in Diagnostics in VS Code:

Screenshot 2022-02-23 at 11 14 57
Screenshot 2022-02-23 at 11 15 03

There's an open issue at microsoft/vscode#54272 requesting this - please add a 👍 to it, and if that's implemented (and then added to LSP), we may be able to add this.

Thanks!

@DanTup DanTup added this to the Backlog milestone Feb 23, 2022
@DanTup DanTup added the blocked on vs code / lsp / dap Requires a change in VS Code to progress label Feb 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked on vs code / lsp / dap Requires a change in VS Code to progress is enhancement
Projects
None yet
Development

No branches or pull requests

2 participants