Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

vue/custom-event-name-casing forcing camelCase on vue2 code #1362

Closed
cain opened this issue Dec 3, 2020 · 3 comments
Closed

vue/custom-event-name-casing forcing camelCase on vue2 code #1362

cain opened this issue Dec 3, 2020 · 3 comments

Comments

@cain
Copy link

cain commented Dec 3, 2020

What rule do you want to change?
Removing rule from vue2 vue/custom-event-name-casing.

Official vue documentation recommends using kebab case for naming custom event names. https://vuejs.org/v2/guide/components-custom-events.html#Event-Names
"For these reasons, we recommend you always use kebab-case for event names."

Does this change cause the rule to produce more or fewer warnings?
Fewer

How will the change be implemented? (New option, new default behavior, etc.)?
Removing rule from plugin:vue/recommended and plugin:vue/essential

Please provide some example code that this change will affect:

$emit('somethingCool') // throws linting error

What does the rule currently do for this code?

What will the rule do after it's changed?

Additional context
version: 7.1

@cain
Copy link
Author

cain commented Dec 3, 2020

@ota-meshi
Copy link
Member

If you are using vue2, we recommend always using kebab-case.
https://vuejs.org/v2/guide/components-custom-events.html#Event-Names

However, for another reason, we plan to remove vue/custom-event-name-casing rule from the configuration.

@cain
Copy link
Author

cain commented Dec 3, 2020

If you are using vue2, we recommend always using kebab-case.
https://vuejs.org/v2/guide/components-custom-events.html#Event-Names

That's the whole point of my issue @ota-meshi

Looking forward to the next release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants