-
Notifications
You must be signed in to change notification settings - Fork 15
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
External fragments are not pulled into the query document using the loader #23
Comments
|
ok let me try it out just now, will give feedback just now. Thanks |
Thank you soo much, it works, but why is this so? I had created a make shift loader that was now at the point of parsing it with gql. I guess I just going to ditch it now coz this has all the features I want and you are very active on issues. I'd rather contribute to this than reinvent the wheel. |
It could help if you throw an error when the import statement is somehow mull-formed and not parsable coz, I am sure the code can detect that an import was being attempted. Double pound should be a real comment even if it contains a valid or invalid import directive. |
I don't know, I didn't write the code. Just saw the question and thought I'd help. |
I see that prisma supports a space between the poundsign and the word import: I think, given that prior art, we would accept a PR that added either:
|
import doesn't seem to contain the fragment specified in # import statement and doesn't handle single quoted paths as well:
contact.fragment.graphql:
profile.graphql:
Further console log scrutiny of the imported graphql query shows that the fragment definition is missing in the AST or imported string.
NOTICE If I combine the two files into one (profile.graphql) then the fragment is defined in the resulting AST document and works flawlessly.
Am I missing something I should do to include the fragment or it's a bug?
The text was updated successfully, but these errors were encountered: