-
Notifications
You must be signed in to change notification settings - Fork 42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix indentation when printing arguments #312
Conversation
@@ -1,7 +1,7 @@ | |||
<Project> | |||
|
|||
<PropertyGroup> | |||
<VersionPrefix>9.0.1-preview</VersionPrefix> | |||
<VersionPrefix>9.0.2-preview</VersionPrefix> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Shane32 I would like to switch to MinVer here like I suggested in graphql-dotnet/graphql-dotnet#3562 so we can see how this looks and feels.
node is GraphQLFieldDefinition || | ||
node is GraphQLEnumValueDefinition || | ||
node is GraphQLRootOperationTypeDefinition || | ||
node is GraphQLDirectiveLocations && Options.EachDirectiveLocationOnNewLine || | ||
node is GraphQLUnionMemberTypes && Options.EachUnionMemberOnNewLine || | ||
node is GraphQLArgumentsDefinition && node.Comments?.Count > 0 |
Check notice
Code scanning / CodeQL
Complex condition Note
@@ -721,7 +721,7 @@ protected override async ValueTask VisitArgumentAsync(GraphQLArgument argument, | |||
protected override async ValueTask VisitArgumentsDefinitionAsync(GraphQLArgumentsDefinition argumentsDefinition, TContext context) | |||
{ | |||
await VisitAsync(argumentsDefinition.Comments, context).ConfigureAwait(false); | |||
await context.WriteAsync("(").ConfigureAwait(false); | |||
await VisitAsync(LiteralNode.Wrap("("), context).ConfigureAwait(false); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
General note - any literal printed first (after optional comment or description node) in VisitXXX
method should be wrapped into LiteralNode
for proper indentation.
Codecov Report
📣 This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more @@ Coverage Diff @@
## master #312 +/- ##
=======================================
Coverage 96.23% 96.23%
=======================================
Files 85 85
Lines 4889 4892 +3
Branches 475 476 +1
=======================================
+ Hits 4705 4708 +3
Misses 184 184
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
fixes #311