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

Add rule metadata to public LinterResult API #6166

Merged
merged 2 commits into from Jun 24, 2022
Merged

Add rule metadata to public LinterResult API #6166

merged 2 commits into from Jun 24, 2022

Conversation

ybiquitous
Copy link
Member

@ybiquitous ybiquitous commented Jun 21, 2022

Which issue, if any, is this issue related to?

Closes #6082

Is there anything in the PR that needs further explanation?

This pull request adds a new property ruleMetadata to the LinterResult type as a public API. The new property should make it easier to write a custom formatter using rule metadata.

Also, this change includes:

  • refactor the verboseFormatter code by using the new property
  • add a rule URL to the githubFormatter output. See the demo and screenshot:
    • Screen Shot 2022-06-22 at 0 37 33

@ybiquitous ybiquitous marked this pull request as ready for review June 21, 2022 15:38
Copy link
Member

@jeddy3 jeddy3 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice, thank you!

@ybiquitous ybiquitous merged commit 8d890c0 into main Jun 24, 2022
@ybiquitous ybiquitous deleted the issue-6082 branch June 24, 2022 00:17
@ybiquitous
Copy link
Member Author

Changelog entry added:

  • Added: rule metadata to public LinterResult API (#6166).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Add rule metadata to public API
2 participants