Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
GraphQL: Fix formatting for directives in fields (#9116)
* Fix formatting for directives in FragmentDefinition * Add changelog * Update src/language-graphql/printer-graphql.js Co-authored-by: Georgii Dolzhykov <thorn.mailbox@gmail.com> * Fix by Prettier * Refactor Co-authored-by: Georgii Dolzhykov <thorn.mailbox@gmail.com>
- Loading branch information
1 parent
a836319
commit d5da779
Showing
4 changed files
with
47 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
#### Fix formatting for directives in fields (#9116 by @sosukesuzuki) | ||
|
||
<!-- prettier-ignore --> | ||
```graphql | ||
# Input | ||
type Query { | ||
someQuery(id: ID!, someOtherData: String!): String! @deprecated @isAuthenticated | ||
versions: Versions! | ||
} | ||
|
||
|
||
# Prettier stable | ||
type Query { | ||
someQuery(id: ID!, someOtherData: String!): String! | ||
@deprecated | ||
@isAuthenticated | ||
versions: Versions! | ||
} | ||
|
||
# Prettier master | ||
type Query { | ||
someQuery(id: ID!, someOtherData: String!): String! | ||
@deprecated | ||
@isAuthenticated | ||
versions: Versions! | ||
} | ||
|
||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters