-
Notifications
You must be signed in to change notification settings - Fork 32
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 "reactivity" triggers on effector stores #6
Comments
Thanks for the report and for using the plugin. You're right in a way, the rule triggers because it matches I think a good solution for you might be to I could be convinced to add an allowlist/blocklist option if you really want to ignore usages of |
effector library has an ESLint plugin, which includes a rule for enforcing store naming conventions. I think it could be a helpful example as to how to validate primitives based on other parameters than name. I'd make a PR but I don't have prior experience in creating ESLint plugins |
Thanks, that example is helpful. The reason I checked by name only and didn't want to track import aliases was because true variable analysis is tricky and potentially expensive. But the method they're using here is much less complicated and should cover 99.9% of cases. It does look like the rule you mentioned can support renaming to |
This issue is fixed with |
Describe the bug
The rule reactivity triggers on effector stores, I assume it's because of naming convention.
To Reproduce
Steps to reproduce the behavior:
const $user = createStore({})
ESLint: Array destructuring should be used to capture the first result of this function call.(solid/reactivity)
Expected behavior
This rule shouldn't trigger on effector stores
Screenshots
If applicable, add screenshots to help explain your problem.
The text was updated successfully, but these errors were encountered: