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
eslint: improve documentation for rule meta properties #61803
eslint: improve documentation for rule meta properties #61803
Conversation
@bmish Thank you for submitting this PR! This is a live comment which I will keep updated. 1 package in this PRCode ReviewsBecause this is a widely-used package, a DT maintainer will need to review it before it can be merged. You can test the changes of this PR in the Playground. Status
All of the items on the list are green. To merge, you need to post a comment including the string "Ready to merge" to bring in your changes. Diagnostic Information: What the bot saw about this PR{
"type": "info",
"now": "-",
"pr_number": 61803,
"author": "bmish",
"headCommitOid": "4dd7317d3505a981a4d58655a204c72a9d1bd89e",
"mergeBaseOid": "9205f7999a9a2ec11cecee84b9af881f834a9bd8",
"lastPushDate": "2022-08-18T21:06:20.000Z",
"lastActivityDate": "2022-08-19T02:14:35.000Z",
"mergeOfferDate": "2022-08-18T23:20:16.000Z",
"mergeRequestDate": "2022-08-19T02:14:35.000Z",
"mergeRequestUser": "JounQin",
"hasMergeConflict": false,
"isFirstContribution": false,
"tooManyFiles": false,
"hugeChange": false,
"popularityLevel": "Critical",
"pkgInfo": [
{
"name": "eslint",
"kind": "edit",
"files": [
{
"path": "types/eslint/index.d.ts",
"kind": "definition"
}
],
"owners": [
"pmdartus",
"j-f1",
"saadq",
"JasonHK",
"bradzacher",
"JounQin"
],
"addedOwners": [],
"deletedOwners": [],
"popularityLevel": "Critical"
}
],
"reviews": [
{
"type": "approved",
"reviewer": "jakebailey",
"date": "2022-08-18T23:19:33.000Z",
"isMaintainer": true
},
{
"type": "approved",
"reviewer": "JounQin",
"date": "2022-08-18T23:08:51.000Z",
"isMaintainer": false
}
],
"mainBotCommentID": 1219951159,
"ciResult": "pass"
} |
🔔 @pmdartus @j-f1 @saadq @JasonHK @bradzacher @JounQin — please review this PR in the next few days. Be sure to explicitly select |
67614c8
to
40d25cd
Compare
40d25cd
to
4dd7317
Compare
Can deprecation be tested? I'm serious, see also https://sonarsource.github.io/rspec/#/rspec/S1874/javascript and it's source at https://github.com/SonarSource/SonarJS/blob/master/eslint-bridge/src/linting/eslint/rules/deprecation.ts. |
@JounQin I'm assuming you mean "deprecation". In the context of my PR, what do you mean by testing deprecation? These deprecated properties are referenced in the DefinitelyTyped eslint test file to ensure they can continue to be used. |
@bmish sorry for my typo. 😅 Yes, I mean can that be tested in favor of function overloads. (Not specific on this PR) |
I'm still not sure what you mean by "tested in favor of function overloads". |
Function A can have different signatures, only a few of them maybe deprecated, I want to have test cases to make sure TS understand which overload usages should be considered as deprecation, which should be used without deprecation notice. For example, |
@JounQin I was hoping something like that existed but haven't found anything. |
Yeah, so I'm just asking, and I'd like to raise an issue on https://github.com/microsoft/TypeScript. |
Ready to merge |
npm test <package to test>
.What's included
meta.docs.category
- see docs: remove unused meta.docs.category field in working-with-rules page eslint/eslint#16109, Unnecessarycategory
field in template for plugin-based rules eslint/generator-eslint#131meta.docs.suggestion
- see Breaking: Requiremeta.hasSuggestions
for rules with suggestions eslint/eslint#14573