Allow deprecation of input values (field args, directive args, input fields)
See original GitHub issueDescribe the bug An unexpected error message “… tried to use a directive ‘deprecated’ in the ‘INPUT_FIELD_DEFINITION’ location but that is illegal”
To Reproduce
- In IntelliJ, create a *.graphqls file
- Type
input MyData {
name: String
surname: String
familyName: String @deprecated
city: String
}
- You get an error on the line
familyName
: “‘familyName’ tried to use a directive ‘deprecated’ in the ‘INPUT_FIELD_DEFINITION’ location but that is illegal”
Expected behavior I don’t think that @deprecated is illegal there - please explain or fix.
Screenshots
Version and Environment Details IntelliJ IDEA 2021.2.3 (Ultimate Edition) Build #IU-212.5457.46, built on October 12, 2021 Runtime version: 11.0.12+7-b1504.40 amd64 VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o. Windows 10 10.0 Non-Bundled Plugins: com.intellij.lang.jsgraphql (3.0.0), com.haulmont.jpab (5.8-212)
Issue Analytics
- State:
- Created 2 years ago
- Reactions:5
- Comments:10
Top Results From Across the Web
Allow deprecation of input values (field args, directive ... - GitHub
and yes, it seems supporting the @deprecated directive on fields. The generated code looks like this: @javax.annotation.processing.Generated( ...
Read more >GraphQL schemas will use the "@deprecated" directive for ...
As of API version 2022-07 all GraphQL schemas will start using the "@deprecated" directive for input fields and arguments which have been ...
Read more >Directives - Apollo GraphQL Docs
Configure GraphQL types, fields, and arguments A directive decorates part of a GraphQL schema or operation with additional configuration. Tools like Apollo ...
Read more >Schema Directives – GraphQL Tools
Using and implementing custom directives to transform schema types, fields, and arguments.
Read more >Deprecating Schema | GraphQL Kotlin
... directive on the fields (which correspond to Kotlin properties and functions), input fields and enum values. Deprecation of arguments is ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Would be awesome to cut a new version of the plugin to get this new feature!
Don’t know about that @vepanimas responded pretty quickly back in November.
Red squiggly lines are haunting me in my dreams… 😥