vue/no-define-model-default
disallow default values in
defineModel
- ❗ This rule has not been released yet.
📖 Rule Details
This rule disallows the default option in defineModel().
When the parent passes undefined through v-model, for example from a ref that has no initial value, the child falls back to the default while the parent still holds undefined, so the two values are out of sync. Leaving out the default and initializing the value in the parent avoids that.
🔧 Options
Nothing.