-
Notifications
You must be signed in to change notification settings - Fork 356
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 the React Compiler linter #11139
Conversation
Preview: https://patternfly-react-pr-11139.surge.sh A11y report: https://patternfly-react-pr-11139-a11y.surge.sh |
Closes patternfly#11137 Signed-off-by: Jon Koops <jonkoops@gmail.com>
4bcc4f9
to
22d4376
Compare
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.
LGTM.
@@ -119,6 +121,7 @@ export default [ | |||
radix: ['error', 'as-needed'], | |||
'react/prop-types': 0, | |||
'react/display-name': 0, | |||
'react-compiler/react-compiler': 'warn', |
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 assume at some point we want to change this to error out when we move to react 19? @tlabaj Do we need a story to revisit this in the future.
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.
Already logged it, see #11138 😉
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.
The error
value can be set once all warnings are fixed, no need to wait for React 19. It only notifies you of patterns that are incompatible with the React Compiler, but does not introduce anything incompatible.
Adds the new React Compiler linter to the linting configuration and sets it to emit warnings where violations are detected. These warnings will need to be fixed and then turned into errors as a follow up (see #11138).
Closes #11137