ESLint Plugin for Vue Accessibility (A11y)

0.0.31 · abandoned · verified Sun Apr 19

This package, `eslint-plugin-vue-a11y`, is an ESLint plugin designed to statically check accessibility rules within Vue.js single-file components (`.vue` files). It aims to help developers identify common accessibility issues in their Vue templates and scripts. However, it is important to note that this specific package, currently at version 0.0.31, has been abandoned. Its last known update was seven years ago, and it only supports older versions of ESLint (peer dependencies `^3 || ^4 || ^5`) and implicitly older Vue.js versions. For modern Vue.js and ESLint environments, the actively maintained and recommended successor is `eslint-plugin-vuejs-accessibility`, which provides similar functionality with ongoing development and compatibility with current toolchains.

Common errors

Warnings

Install

Imports

Quickstart

This `.eslintrc.json` snippet demonstrates how to configure the `eslint-plugin-vue-a11y` plugin, enabling its base rules and a few specific rules. This configuration is for the abandoned package and is not compatible with modern ESLint or Vue.js projects. Consider using `eslint-plugin-vuejs-accessibility` instead.

{
  "root": true,
  "env": {
    "node": true
  },
  "extends": [
    "eslint:recommended",
    "plugin:vue/recommended",
    "plugin:vue-a11y/base" // Or "plugin:vue-a11y/recommended"
  ],
  "plugins": [
    "vue-a11y"
  ],
  "rules": {
    // Example: Override or add specific rules
    "vue-a11y/alt-text": ["error", { "elements": ["img", "area", "input[type='image']"] }],
    "vue-a11y/accessible-emoji": "warn"
  },
  "parserOptions": {
    "parser": "@babel/eslint-parser", // Adjust based on your setup (e.g., @typescript-eslint/parser for TS)
    "ecmaVersion": 2018,
    "sourceType": "module"
  }
}

view raw JSON →