feat!: cross test function-call-spacing#565
feat!: cross test function-call-spacing#565antfu merged 5 commits intoeslint-stylistic:maineslint-stylistic/eslint-stylistic:mainfrom 9romise:refactor/merge(func-call-spacing)9romise/eslint-stylistic:refactor/merge(func-call-spacing)Copy head branch name to clipboard
function-call-spacing#565Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #565 +/- ##
==========================================
- Coverage 96.94% 96.23% -0.71%
==========================================
Files 121 121
Lines 20340 20352 +12
Branches 4842 4816 -26
==========================================
- Hits 19718 19586 -132
- Misses 619 762 +143
- Partials 3 4 +1 ☔ View full report in Codecov by Sentry. |
|
I don't have an idea of how to do the incremental breaking changes yet. On one hand I want to get them out one-by-one as soon as possible for users to test out, but on the other hand, we can't just do breaking changes for every single rule. Do you have any idea on that? Is that possible to still keep the original behavior and then break the default options all together (when we finish the migration of all rules)? |
|
Maybe we could make a factory function to create two version of rules with different defaults, use it to create two different entry? |
|
After careful consideration, I think that this PR contains too much content. Maybe I should split it up and submit.
Some safe changes (or maybe fixes)
Since the core problem is the difference in the optional chain, I think maybe we can just add an option for the user to choose, which can also get a better auto-fix.
There are some syntax errors in the issue description, so we can do without porting it. Completing these changes one by one may reduce the breaking changes. |
|
Oh yeah that would do. We could merge those non-breaking PRs and ship them, while we could mark all the needed breaking PRs draft (and keep them as small as possible), and finally merge then when we do majors. |
85b5d77 to
11e83d8
Compare
|
Updated the description at the top, this PR should be merged after #606 |
Description
Auto-fixing optional chain is different in the two versions.
Changes:
ImportExpressionintsversion (feat(function-call-spacing): supportImportExpressionintsversion #570)never(feat(function-call-spacing): auto-fix optional chain when option isnever#589)optionChainto controlf?. (),f ?.(),f ?. ()when the option isalways(feat(function-call-spacing): addoptionalChainwhen option isalways#605)never#606)Linked Issues
part of #482
Additional context