feat(linter): change react/rules-of-hooks category to pedantic#7691
Merged
graphite-app[bot] merged 1 commit intomainfrom Dec 6, 2024
Conversation
Contributor
Your org has enabled the Graphite merge queue for merging into mainAdd the label “0-merge” to the PR and Graphite will automatically add it to the merge queue when it’s ready to merge. Or use the label “hotfix” to add to the merge queue as a hot fix. You must have a Graphite account and log in to Graphite in order to use the merge queue. Sign up using this link. |
Contributor
Merge activity
|
…7691) Although this rule is recommended by the React team, it does not report incorrect or wrong code for the `correctness` category. When turned on by default, I find false positive warnings confusing, I cannot tell whether my code is wrong or the rule implementation is wrong - see examples in the affine repo. ``` x eslint-plugin-react-hooks(rules-of-hooks): React Hook "use" cannot be called at the top level. React Hooks must be called in a React function component or a custom React Hook function. ,-[packages/backend/server/src/config/affine.self.ts:80:1] 79 | /* Captcha Plugin Default Config */ 80 | ,-> AFFiNE.use('captcha', { 81 | | turnstile: {}, 82 | | challenge: { 83 | | bits: 20, 84 | | }, 85 | `-> }); 86 | `---- ```
106bd4f to
fd0935c
Compare
CodSpeed Performance ReportMerging #7691 will not alter performanceComparing Summary
|
Contributor
|
we are roporting correctly in Affine repo. |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.

Although this rule is recommended by the React team,
it does not report incorrect or wrong code for the
correctnesscategory.When turned on by default, I find false positive warnings confusing,
I cannot tell whether my code is wrong or the rule implementation is
wrong - see examples in the affine repo.