-
-
Notifications
You must be signed in to change notification settings - Fork 4.6k
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
feat: introduce new deprecated types for rules #19238
Merged
+5,258
−887
Merged
Changes from 1 commit
Commits
Show all changes
51 commits
Select commit
Hold shift + click to select a range
bb8a2b2
feat: introduce new deprecated types
DMartens 0a8be53
feat: rules use new deprecated format
DMartens c4d9c9b
feat: support new deprecated format in usedDeprecatedRules
DMartens 60bc4f9
docs: document new deprecated format
DMartens 09a07cd
fix: Use formatting rules instead of stylistic rules are being removed
DMartens cb8202e
fix: Clarify the replacement is from ESLint Stylistic
DMartens 2d28ec3
docs: automatically add deprecated rules notice
DMartens 3eb611d
docs: handle missing replacement rule for rule deprecations
DMartens 816166e
Merge branch 'main' into deprecated-rule-metadata
DMartens 9bcb965
docs: stop checking for manually added rule deprecation notices
DMartens a887786
docs: apply suggestions
DMartens 0a0e7f5
docs: fix lint errors
DMartens f9726e3
docs: Clarify null for availableUntil is not the same as frozen
DMartens 27dd0f3
fix: rule deprecation messages for node and various suggestions
DMartens a4ef007
fix: internal links
DMartens 47e7445
fix: sync deprecated node rules messages and descriptions
DMartens a2df4e7
fix: add rule deprecation type tests
DMartens 86158e8
fix: re-add .md file extension for rules from eslint-plugin-n
DMartens ad2e3e6
fix: add periods to sentence ends
DMartens 3789bc1
fix: showing rule replacements for deprecated and removed rules in ru…
DMartens 00418a2
fix: add urls for replacement of deprecated rules in favor of padding…
DMartens 2119a57
fix: always provide a rule meta.deprecated.url
DMartens 9da6e1d
fix: alias func-call-spacing as the replacement rule is renamed to ke…
DMartens 8baace5
fix: convert callback-return and indent-legacy to new deprecated format
DMartens 79d3579
fix: normalize deprecated rule messages
DMartens ac457e4
chore: fix single quotes in eslint tests
DMartens 72e07e8
fix: use external links to rule replacements in the rule reference
DMartens 72cdd02
fix: remove shadowing of rule in makefile
DMartens 70439e3
fix: add external plugin reference for deprecated rules in the rule r…
DMartens fd5557e
fix: remove manual deprecation notice of no-new-object
DMartens 2ae6aab
fix: cleanup rule-list macro
DMartens a1b4c82
fix: update rule-list documentation
DMartens a1ec4a6
fix: use DeprecatedInfo type from @eslint/core
DMartens 398ccf1
Merge branch 'main' into deprecated-rule-metadata
DMartens aadbd4e
fix: use shorthand plugin names for usedDeprecatedRules
DMartens 78f512e
fix: restore check for deprecated JSDoc tags for rule files
DMartens ad91560
fix: adjust JSDoc description and error message as README no longer c…
DMartens f2546ae
fix: use correct name in deprecation info for arrow-spacing
DMartens c2e14d3
fix: use correct name in deprecation info for multiline-comment-style
DMartens dd4c6b5
fix: correct package source of eslint-plugin-n in replacement infos
DMartens 1a9732a
fix: rule docs site uses relative pages for internal rule replacements
DMartens c1eb5c0
fix: deprecation rule for no-buffer-constructor
DMartens 264be63
fix: deprecation rule for no-restricted-modules
DMartens f1937a9
docs: Add dot at the end of a core rule replacement.
DMartens 52e151f
fix: use relative links for replacement rules in the rule reference
DMartens b4a966d
fix: rule-type-list data for removed rules use new replacement format
DMartens fecc7f9
fix: no rendering of replacement rule lists if there are no replacements
DMartens 3183761
fix: run pretteir on rule-type-list.json
DMartens 3b626ae
docs: change description of `url` for deprecation meta
DMartens 35d36d5
fix: deprecation version of no-spaced-fnc
DMartens ff3666f
fix: replacement rule of no-new-symbol
DMartens File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
feat: support new deprecated format in usedDeprecatedRules
- Loading branch information
commit c4d9c9bed49f40fab6556bdfaee8b0750925c5bf
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
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
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
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
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I checked again the RFC and it's not indicated how normalizing rule names for
usedDeprecatedRules
should work in the case of external rules. With this logic, the replacement rule names would look like"@stylistic/eslint-plugin-js/semi"
, but the standard notation for such a rule in a configuration object is"@stylistic/js/semi"
. Shall we use this format instead? Or something else? @eslint/eslint-tscThe short form of the plugin prefix can be retrieved with
naming.getShorthandName
like here: https://github.com/eslint/eslint/blob/e89a54a3090f3503daf5e36b02b0035c993e3fd1/lib/eslint/eslint.js#L499C25-L499C66There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should use the name as it would likely appear in the config, so
@stylistic/js/semi
would be my choice.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm also in favor of normalizing to
@stylistic/js/semi
.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should the shorthand name also be used when displaying the replacement rules in the documentation?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't have a strong preference, but I think it's fine to be more descriptive in the documentation. The current format "Replaced by
semi
in@stylistic/eslint-plugin-js
" sounds good to me.