vue/no-duplicate-attr-inheritance
enforce
inheritAttrsto be set tofalsewhen usingv-bind="$attrs"
📖 Rule Details
This rule aims to prevent duplicate attribute inheritance.
This rule suggests applying inheritAttrs: false when it detects v-bind="$attrs" being used.
🔧 Options
json
{
"vue/no-duplicate-attr-inheritance": ["error", {
"checkMultiRootNodes": false,
}]
}"checkMultiRootNodes": If set totrue, also suggest applyinginheritAttrs: falseto components with multiple root nodes (whereinheritAttrs: falseis the implicit default, see attribute inheritance on multiple root nodes), whenever it detectsv-bind="$attrs"being used. Default isfalse, which will ignore components with multiple root nodes.
"checkMultiRootNodes": true
📚 Further Reading
🚀 Version
This rule was introduced in eslint-plugin-vue v7.0.0