Back to Prettier

Input

changelog_unreleased/graphql/19297.md

3.9.0560 B
Original Source

Support "Fragment arguments" (#19297 by @fisker)

Fragment arguments are now supported.

<!-- prettier-ignore -->
gql
# Input
fragment variableProfilePic on User {
  ...dynamicProfilePic(size: $size)
}

# Prettier stable
SyntaxError: Syntax Error: Expected Name, found "(". (2:23)
  1 | fragment variableProfilePic on User {
> 2 |   ...dynamicProfilePic(size: $size)
    |                       ^
  3 | }

# Prettier main
fragment variableProfilePic on User {
  ...dynamicProfilePic(size: $size)
}