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

Fix broken parse-literal-occurences on syntax errored code #43

Merged
merged 2 commits into from
Jan 31, 2023

Conversation

Chnapy
Copy link
Owner

@Chnapy Chnapy commented Jan 31, 2023

Literal occurences parsing was done by @graphql-tools/graphql-tag-pluck, which uses babel/parsel behind. Babel does not work with syntax broken code, so graphql-tag-pluck cannot be used for this issue.

In a previous iteration, a solution using TS api with AST visitor was made, which works with syntax broken code, even with better performances => first commit of this PR #22. This solution is clearly better.

fix #41

@Chnapy Chnapy merged commit f16f6ba into master Jan 31, 2023
@Chnapy Chnapy deleted the fix-parse-literal-occurences-with-syntax-error branch January 31, 2023 01:19
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

Successfully merging this pull request may close these issues.

Typing broken when file has syntax error
1 participant