-
Notifications
You must be signed in to change notification settings - Fork 103
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
vscode-eslint error when running in mono repo packages #105
Comments
Thanks - I noticed this recently too. We need to use a different function
from ‘GraphQL-config’ but unfortunately they don’t transpire yet and it
would affect our compat matrix. I’m working on getting those upstream
dependencies compatible and that should get us the behavior we expect
…On Sun, Jan 21, 2018 at 8:59 PM Jayden Seric ***@***.***> wrote:
With this repo/project structure:
- api/
- app/
- components/
- schema.graphql
- .graphqlconfig (with "schemaPath": "schema.graphql")
- package.json (with eslintConfig and eslint-plugin-graphql
configured)
vscode-eslint <https://github.com/Microsoft/vscode-eslint> displays this
error when attempting to lint files in /app/components containing GraphQL
syntax:
[image: screen shot 2018-01-22 at 3 40 02 pm]
<https://user-images.githubusercontent.com/1754873/35205728-9e7721b8-ff8b-11e7-88f9-04254992aec2.png>
The error (which BTW in a narrow window cuts off with an ellipses without
being able scroll) suggests looking at the ESLint output, which doesn't
show any errors:
[image: screen shot 2018-01-22 at 3 40 42 pm]
<https://user-images.githubusercontent.com/1754873/35205804-2358a262-ff8c-11e7-8286-2ba9462310d4.png>
Interestingly, moving .graphqlconfig and schema.graphql out into the root
of the project solves the errors.
Adding ./ to the schemaPath in app/.graphqlconfig has no effect.
Running eslint . in Terminal within /app works ok.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#105>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ABERRjcGzPZSPokKbOPrU9T3eLPouSueks5tNBW4gaJpZM4RmKzj>
.
|
Looks like |
The function we use is compatible back to Node 4 but the one we want
(findconfigforfile or something) is Node 8
…On Sun, Jan 21, 2018 at 9:06 PM Jayden Seric ***@***.***> wrote:
Looks like graphql-config does not have a package.json engines field
<https://github.com/graphcool/graphql-config/blob/master/package.json>. I
can't easily tell what versions of Node.js are supported.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#105 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ABERRgSr0-qSKnc9RIrBMMDqfAxgliqHks5tNBdBgaJpZM4RmKzj>
.
|
As a really gross temporary workaround, you can create symbolic links in the project root: ln -s app/.graphqlconfig .graphqlconfig
ln -s app/schema.graphql schema.graphql |
this affects atom too. see kamilkisiela/graphql-config#84 and ardatan/graphql-import#63 which should allow us to use |
5 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
With this repo/project structure:
"schemaPath": "schema.graphql"
)eslintConfig
andeslint-plugin-graphql
configured)vscode-eslint
displays this error when attempting to lint files in/app/components
containing GraphQL syntax:The error (which BTW in a narrow window cuts off with an ellipses without being able scroll) suggests looking at the ESLint output, which doesn't show any errors:
Interestingly, moving
.graphqlconfig
andschema.graphql
out into the root of the project solves the errors. This is not a solution though.Adding
./
to theschemaPath
inapp/.graphqlconfig
has no effect.Running
eslint .
in Terminal within/app
works ok.The text was updated successfully, but these errors were encountered: