vue/no-boolean-default
disallow boolean defaults
The rule prevents Boolean props from having a default value.
📖 Rule Details
The rule is to enforce the HTML standard of always defaulting boolean attributes to false.
🔧 Options
'no-default'
(default) allows a prop definition object, but enforces that thedefault
property not be defined.'default-false'
enforces that the default can be set but must be set tofalse
.
json
"vue/no-boolean-default": ["error", "no-default|default-false"]
👫 Related Rules
🚀 Version
This rule was introduced in eslint-plugin-vue v7.0.0