jsx-eslint / eslint-plugin-jsx-a11y

Static AST checker for a11y rules on JSX elements.
MIT License
3.39k stars 637 forks source link

anchor-has-content false negative in mdx file #917

Open smellai opened 1 year ago

smellai commented 1 year ago

Screenshot 2023-01-17 alle 16 35 55

works fine in jsx files in the same project

ljharb commented 1 year ago

What's your eslint config? i have no idea what would parse mdx.

smellai commented 1 year ago

I have this configuration in eslintrc:

"overrides": [
    {
      "files": ["*.mdx"],
      "extends": ["plugin:mdx/recommended"]
    }
  ]

Reference: https://www.npmjs.com/package/eslint-plugin-mdx

ljharb commented 1 year ago

Since it claims it works perfectly with eslint-plugin-import, you may want to file a bug on that plugin.