Please describe what the rule should do:
This rule requires prop and event properties in model property.
What category should the rule belong to?
Provide 2-3 code examples that this rule should warn about:
<script>
export default {
model: {
prop: 'someValue',
// Needs 'event' property.
},
};
</script>
<script>
export default {
model: {
props: 'someValue', // Needs 'prop' property.
event: 'some-event',
},
};
</script>
Additional context
- If settings is missing, v-model uses
value as the prop and input as the event. But both settings should be required when use model property.
- Miss-typing with property name is easy to occur and founding the mistake is much harder.