graphql / vscode-graphql

MIGRATED: VSCode GraphQL extension (autocompletion, go-to definition, syntax highlighting)
https://marketplace.visualstudio.com/items?itemName=Prisma.vscode-graphql
MIT License
557 stars 71 forks source link

queries always sent to the first project's graphql endpoint #316

Closed waterdrop01 closed 3 years ago

waterdrop01 commented 3 years ago

Actual Behavior

Here is my .graphqlrc.yml config file:

projects:
  first:
    schema: ./first.graphql
    documents: ./src/first-gql.js
    extensions:
      endpoints:
        default:
          url: https://first
  second:
    schema: ./second.graphql
    documents: ./src/second-gql.js
    extensions:
      endpoints:
        default:
          url: https://second

When in the ./src/second-gql.js file, and clicking on the "query" button, the request is sent to https://first.

Expected Behavior

Depending on the file? the query should be routed to the correct endpoint

Logs Of TS Server || GraphQL Language Service

NetworkHelper: operation: query
NetworkHelper: endpoint: https://first
waterdrop01 commented 3 years ago

solved by this fix https://github.com/dotansimha/graphql-eslint/issues/526