Closed
Description
What rule do you want to change?
vue/no-dupe-keys behavior in 8.0.0
Does this change cause the rule to produce more or fewer warnings?
- When using TypeScript, asyncData values must be duplicated in data in order to make them typed
- I may not return all params in asyncData, in that case data property will work like default value.
How will the change be implemented? (New option, new default behavior, etc.)?
Rollback asyncData support for vue/no-dupe-keys
Please provide some example code that this change will affect:
export default Vue.extend({
async asyncData() {
return {
isPopupVisible: true,
};
},
data() {
return {
isPopupVisible: false,
};
},
mounted() {
this.isPopupVisible = true;
//...
}
});
What does the rule currently do for this code?
Duplicated key 'isPopupVisible'.(vue/no-dupe-keys)
for data property. If I remove it from data, I will get Property 'isPopupVisible' does not exist on type 'CombinedVueInstance >>'
What will the rule do after it's changed?
This code works as intended.
New behavior leaves no choice but to disable this rule or place eslint-ignore everywhere. Yet, I have to stay on 7.x.