-
-
Notifications
You must be signed in to change notification settings - Fork 22
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
static properties typo #38
Comments
This would align with the work @43081j and I had discussed related to typos. Would be able to handle lit specific lifecycle hooks and public members. Would be similar to the eslint-plugin-wc no-typos rule. I'm not sure if we want to cover the static vs non-standard case as it is valid to have a non-static properties getter |
Are you sure? the properties getter is accessed in the Should indeed be a no-typos equivalent for lit, though, like the wc plugin has. |
@43081j So you want to say a user is incorrect for using something else named You are correct that if they want to use it for the lit-element properties declaration it should be static but I don't know that we should enforce that Or if we do, it should be a separate rule IMO. |
i don't want to say a properties method is invalid, i just meant its not used by lit (not valid by lit). sorry for the confusion. i wouldn't disallow it as its fine to have yourself. i thought you meant it was valid to have it for lit to use it |
It can be an option. I would not recommend having the same property name for instance and static. |
A good linting rule could be to ensure people aren't making a typo in the static properties getter, or use incorrect modifiers:
The text was updated successfully, but these errors were encountered: