vue/v-on-style
eslint-plugin-vue
Safe autofixRecommended
eslint.config.js
import vue from "eslint-plugin-vue";
export default [
{
plugins: { vue },
rules: {
"vue/v-on-style": "error",
},
},
]; <div v-on:click="foo" />
</template> <div @click="foo" />
</template><div @click="foo" /><div v-on:click="foo" />Examples from the ESLint documentation.
vue/v-on-style
eslint-plugin-vue
import vue from "eslint-plugin-vue";
export default [
{
plugins: { vue },
rules: {
"vue/v-on-style": "error",
},
},
];Oxlint does not have this rule.
style/useVueConsistentVOnStyle
style · since 2.3.11
{
"linter": {
"rules": {
"style": {
"useVueConsistentVOnStyle": "error"
}
}
}
}Require emits option with name triggered by $emit()
Disallow passing multiple arguments to scoped slots
Enforce that each component should be in its own file
Enforce props with default values to be optional