question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Relay support] @argumentDefinitions

See original GitHub issue

Steps to Reproduce the Problem Or Description

  1. After adding the Relay Definition from this: graphql/graphiql#2330
  2. Relay specific directives won’t give any problems anymore, for example: @connection
  3. However, @argumentDefinitions has a problem: image
  4. As you can see, the @argumentDefinitions itself can be identified, but the arguments inside can not be, the definition looks like this: directive @argumentDefinitions on FRAGMENT_DEFINITION

Suggestion

I think it might be better if we can ignore validation for certain directives details? For example, we can validate @argumentDefinitions but not its specific arguments list, because they are purely client-side spec unless you write it somewhere, not to mention it could change according to where it is being used.

Specifications

GraphQL for VSCode Extension Version: latest from store Version: 1.49.1 Commit: 58bb7b2331731bf72587010e943852e13e6fd3cf Date: 2020-09-16T23:21:17.533Z Electron: 9.2.1 Chrome: 83.0.4103.122 Node.js: 12.14.1 V8: 8.3.110.13-electron.0 OS: Darwin x64 19.6.0

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:5
  • Comments:10 (5 by maintainers)

github_iconTop GitHub Comments

10reactions
acaocommented, Oct 7, 2020

relay support is coming in a seperate plugin!

3reactions
alloycommented, Apr 19, 2022

Yes, the existing vscode-apollo-relay validation rule does a bunch of @argumentDefinitions validations! 👍

As for Horizon Zero Dawn, I do not but it’s great to know that they are making characters after me 😛

Read more comments on GitHub >

github_iconTop Results From Across the Web

GraphQL Directives | Relay
@arguments is a directive used to pass arguments to a fragment that was defined using @argumentDefinitions . For example: query TodoListQuery($userID: ID) {...
Read more >
[Relay support] @argumentDefinitions · Issue #2331 - GitHub
Steps to Reproduce the Problem Or Description. After adding the Relay Definition from this: How to add definition for custom directives?
Read more >
Relay directives | Martin Zlámal
Relay supports many (mostly) client-only directives which help you to ... used to pass arguments to a fragment that was defined using @argumentDefinitions...
Read more >
GraphQL in Relay
@arguments is a directive used to pass arguments to a fragment that was defined using @argumentDefinitions . For example: query TodoListQuery($userID: ID) { ......
Read more >
GraphQL Relay defaultValue for array of object in fragment ...
export default createRefetchContainer( translate('admin')(UserList), graphql` fragment UserList_usersWithPage on Query @argumentDefinitions( ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found