-
Notifications
You must be signed in to change notification settings - Fork 11
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
Rule suggestion: events hash key should always be quoted #65
Comments
You are correct. It would clash with |
Is there any rule on how to handle clashing rules? It seems like that kind of behavior is greatly discouraged and should probably be handled inside original rule with custom option. |
Yes, usually you would want to resolve it in the core rule. However, ESLint doesn't make exceptions for specific frameworks, all of the rules are framework agnostic. Now that I'm looking at the rule, I think you can just use |
It might be possible to create a plugin version of this rule using eslint-rule-composer. |
When you use events hash, you always quote key since it contains spaces:
But if you try to set event handle on
el
itself, it is allowed to omit those quotes:Suggested rule will warn user to always put quotes around events hash key to keep it consistent with majority of use cases.
Potential issue I can see is that it could clash with
quote-props
rule.What do you think?
The text was updated successfully, but these errors were encountered: