Skip to content
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

Fix curly brace erroring on child text nodes #133

Merged
merged 2 commits into from
Nov 15, 2023
Merged

Conversation

benjervis
Copy link

Prevents the new curly brace rule from affecting text in React children, and only looks at prop values.

See changeset for additional details.

@benjervis benjervis requested a review from a team as a code owner November 15, 2023 03:30
Copy link

changeset-bot bot commented Nov 15, 2023

🦋 Changeset detected

Latest commit: 903a845

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
eslint-config-seek Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@@ -12,7 +12,7 @@ const reactRules = {
'react/prop-types': OFF,
'react/jsx-curly-brace-presence': [
ERROR,
{ props: 'never', children: 'never', propElementValues: 'always' },
{ props: 'never', children: 'ignore', propElementValues: 'always' },
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sounds marginally better than a never child policy

@benjervis benjervis merged commit 1a3c621 into master Nov 15, 2023
3 checks passed
@benjervis benjervis deleted the fix-curly-braces branch November 15, 2023 03:36
@seek-oss-ci seek-oss-ci mentioned this pull request Nov 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants