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

# eslint-disable-next-line clashes with graphql-eslint's processor #153

Open
alecmev opened this issue Sep 24, 2024 · 0 comments
Open

# eslint-disable-next-line clashes with graphql-eslint's processor #153

alecmev opened this issue Sep 24, 2024 · 0 comments

Comments

@alecmev
Copy link
Contributor

alecmev commented Sep 24, 2024

If I enable graphql-eslint's processor for Relay code, ESLint starts treating the GraphQL strings inside that code as standalone GraphQL files. That means eslint-plugin-relay is no longer enabled for them, if it's configured to match *.jsx or something. So when I try to use # eslint-disable-next-line relay/unused-fields I get Definition for rule 'relay/unused-fields' was not found from ESLint, which is expected behavior.

My current workaround is to add *.graphql to eslint-plugin-relay's files array, but that's suboptimal, as it's configuration bloat (and probably also has a runtime penalty). Not sure what's the best way to go about this, but using a processor, as suggested in #152, would help.

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

1 participant