Skip to content

Conversation

ccpu
Copy link
Contributor

@ccpu ccpu commented Jul 27, 2025

Description

This PR adds support for JSX accessibility (a11y) rules using the eslint-plugin-jsx-a11y.
it can be enable as follow:

jsx: {
  a11y: true
}

or customize with overrides:

jsx: {
  a11y: {
    overrides: { /* custom a11y rules */ }
  }
}

I chose to integrate a11y as a sub-option of the jsx prop for a unified, DRY, and extensible API mirroring the approach used for Vue a11y. This keeps all JSX related config in one place and makes future extension easier.

Additional context

  • eslint-plugin-jsx-a11y is widely adopted and considered an industry standard, so having it included in this library would be nice.
  • I have added a separate test to ensure a11y rules are applied correctly.
  • Please check the new config structure and let me know if further tweaks are needed.

Copy link

netlify bot commented Jul 27, 2025

Deploy Preview for melodious-froyo-4871f8 ready!

Name Link
🔨 Latest commit c3b6fbc
🔍 Latest deploy log https://app.netlify.com/projects/melodious-froyo-4871f8/deploys/688746ff83e63e00089062ba
😎 Deploy Preview https://deploy-preview-743--melodious-froyo-4871f8.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@antfu antfu merged commit aeeeb14 into antfu:main Jul 29, 2025
8 checks passed
pixpilot-pacakge-releaser bot pushed a commit to pixpilot/antfu-eslint-config that referenced this pull request Jul 29, 2025
# [2.1.0](v2.0.1...v2.1.0) (2025-07-29)

### Features

* add eslint-plugin-jsx-a11y via jsx.a11y option ([antfu#743](https://github.com/pixpilot/eslint-config/issues/743)) ([aeeeb14](aeeeb14))
* **jsx-a11y:** add accessibility rules for JSX components ([d4dfed9](d4dfed9))
* upgrade `eslint-plugin-jsdoc` to v52 ([80e4a8a](80e4a8a))
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