Closed
Description
What rule do you want to change?
vue/match-component-file-name
Does this change cause the rule to produce more or fewer warnings?
Same.
How will the change be implemented? (New option, new default behavior, etc.)?
New suggestions that can be applied by the user via the editor:
- "Rename component to match file name." (without file extension)
- "Rename file to match component name." (not sure if ESLint suggestions can rename files though)
Note that we can't add an auto-fix here because the user intent is not clear.
Please provide some example code that this change will affect:
// file name: "MySuperCoolComponent.vue"
export default {
name: 'MyAwesomeComponent',
}
What does the rule currently do for this code?
Report, but no auto-fix and no suggestions.
What will the rule do after it's changed?
Report, still no auto-fix, but suggestions.
- Rename component to match file name.
// file name: "MySuperCoolComponent.vue" export default { name: 'MySuperCoolComponent', }
- Rename file to match component name.
// file name: "MyAwesomeComponent.vue" export default { name: 'MyAwesomeComponent', }