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

jsx/jsx-props-no-multi-spaces: no rule enforcement between last prop and self-closing tag #301

Open
3 of 5 tasks
easternmotors opened this issue Mar 20, 2024 · 0 comments

Comments

@easternmotors
Copy link

easternmotors commented Mar 20, 2024

Validations

Describe the bug

When enabling jsx/jsx-props-no-multi-spaces:

// Desired end state
<Component
  propA="foo"
  propB="bar"
/>

// This properly shows an error - Expected no line gap between “Component” and “propA”
<Component

  propA="foo"
  prop2="bar"
/>

// This properly shows an error - Expected no line gap between “propA” and “propB”
<Component
  propA="foo"

  propB="bar"
/>

// This does not show an error
// I would expect the lint error message to say something like - Expected no line gap between “propB” and self-closing tag
<Component
  propA="foo"
  propB="bar"

/>

Contributes

  • I am willing to submit a PR to fix this issue
  • I am willing to submit a PR with failing tests
@easternmotors easternmotors changed the title jsx/jsx-props-no-multi-spaces: not enforce between last prop and self-closing tag jsx/jsx-props-no-multi-spaces: no rule enforcement between last prop and self-closing tag Mar 20, 2024
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

No branches or pull requests

1 participant