Support trailing commas for function calls (#2257)
This commit is contained in:
1 parent
cc85769231
commit
6663bab8a3
3 files changed
+43
-11
No files matched your search
@@ -41,6 +41,7 @@ function genericPrint(path, options, print) {
|
||||
)
|
||||
])
|
||||
),
|
||||
options.trailingComma === "none" ? "" : ifBreak(","),
|
||||
softline,
|
||||
")"
|
||||
])
|
||||
|
||||
@@ -1,8 +1,12 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`trailing.graphql 1`] = `
|
||||
fragment Visit on HighlightedVisit
|
||||
@argumentDefinitions(
|
||||
query CityGuidesSocialUnitRendererQuery(
|
||||
$pageID: ID!
|
||||
$scale: Float
|
||||
$SOCIAL_UNIT_PROFILE_PICTURE_SIZE: Int
|
||||
$SOCIAL_UNIT_CARD_SIZE: Int
|
||||
) @argumentDefinitions(
|
||||
count: {type: "Int", defaultValue: 20, someSuperSuperSuperSuperLongType: 301}
|
||||
test: [{type: "Int", defaultValue: 20, someSuperSuperSuperSuperLongType: 301}]
|
||||
) {
|
||||
@@ -18,7 +22,12 @@ fragment Visit on HighlightedVisit
|
||||
}
|
||||
}
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
fragment Visit on HighlightedVisit
|
||||
query CityGuidesSocialUnitRendererQuery(
|
||||
$pageID: ID!,
|
||||
$scale: Float,
|
||||
$SOCIAL_UNIT_PROFILE_PICTURE_SIZE: Int,
|
||||
$SOCIAL_UNIT_CARD_SIZE: Int
|
||||
)
|
||||
@argumentDefinitions(
|
||||
count: {
|
||||
type: "Int",
|
||||
@@ -43,8 +52,12 @@ fragment Visit on HighlightedVisit
|
||||
`;
|
||||
|
||||
exports[`trailing.graphql 2`] = `
|
||||
fragment Visit on HighlightedVisit
|
||||
@argumentDefinitions(
|
||||
query CityGuidesSocialUnitRendererQuery(
|
||||
$pageID: ID!
|
||||
$scale: Float
|
||||
$SOCIAL_UNIT_PROFILE_PICTURE_SIZE: Int
|
||||
$SOCIAL_UNIT_CARD_SIZE: Int
|
||||
) @argumentDefinitions(
|
||||
count: {type: "Int", defaultValue: 20, someSuperSuperSuperSuperLongType: 301}
|
||||
test: [{type: "Int", defaultValue: 20, someSuperSuperSuperSuperLongType: 301}]
|
||||
) {
|
||||
@@ -60,7 +73,12 @@ fragment Visit on HighlightedVisit
|
||||
}
|
||||
}
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
fragment Visit on HighlightedVisit
|
||||
query CityGuidesSocialUnitRendererQuery(
|
||||
$pageID: ID!,
|
||||
$scale: Float,
|
||||
$SOCIAL_UNIT_PROFILE_PICTURE_SIZE: Int,
|
||||
$SOCIAL_UNIT_CARD_SIZE: Int,
|
||||
)
|
||||
@argumentDefinitions(
|
||||
count: {
|
||||
type: "Int",
|
||||
@@ -85,8 +103,12 @@ fragment Visit on HighlightedVisit
|
||||
`;
|
||||
|
||||
exports[`trailing.graphql 3`] = `
|
||||
fragment Visit on HighlightedVisit
|
||||
@argumentDefinitions(
|
||||
query CityGuidesSocialUnitRendererQuery(
|
||||
$pageID: ID!
|
||||
$scale: Float
|
||||
$SOCIAL_UNIT_PROFILE_PICTURE_SIZE: Int
|
||||
$SOCIAL_UNIT_CARD_SIZE: Int
|
||||
) @argumentDefinitions(
|
||||
count: {type: "Int", defaultValue: 20, someSuperSuperSuperSuperLongType: 301}
|
||||
test: [{type: "Int", defaultValue: 20, someSuperSuperSuperSuperLongType: 301}]
|
||||
) {
|
||||
@@ -102,7 +124,12 @@ fragment Visit on HighlightedVisit
|
||||
}
|
||||
}
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
fragment Visit on HighlightedVisit
|
||||
query CityGuidesSocialUnitRendererQuery(
|
||||
$pageID: ID!,
|
||||
$scale: Float,
|
||||
$SOCIAL_UNIT_PROFILE_PICTURE_SIZE: Int,
|
||||
$SOCIAL_UNIT_CARD_SIZE: Int,
|
||||
)
|
||||
@argumentDefinitions(
|
||||
count: {
|
||||
type: "Int",
|
||||
|
||||
@@ -1,5 +1,9 @@
|
||||
fragment Visit on HighlightedVisit
|
||||
@argumentDefinitions(
|
||||
query CityGuidesSocialUnitRendererQuery(
|
||||
$pageID: ID!
|
||||
$scale: Float
|
||||
$SOCIAL_UNIT_PROFILE_PICTURE_SIZE: Int
|
||||
$SOCIAL_UNIT_CARD_SIZE: Int
|
||||
) @argumentDefinitions(
|
||||
count: {type: "Int", defaultValue: 20, someSuperSuperSuperSuperLongType: 301}
|
||||
test: [{type: "Int", defaultValue: 20, someSuperSuperSuperSuperLongType: 301}]
|
||||
) {
|
||||
|
||||
Reference in new issue
Block a user