Skip to content
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

Default Variables in inline Inputs aren't generated. #1014

Closed
Yamashou opened this issue Feb 6, 2020 · 1 comment
Closed

Default Variables in inline Inputs aren't generated. #1014

Yamashou opened this issue Feb 6, 2020 · 1 comment

Comments

@Yamashou
Copy link

Yamashou commented Feb 6, 2020

What happened?

I want to get inline default values when don't set value

What did you expect?

get inline default values when don't set value like #73

Minimal graphql.schema and models to reproduce

schema

type Query {
 hoge Hoge!
}

type Hoge {
    foos(first: Int = 1000, after: String, orderBy: SubscriptionOrder = {field: CREATED_AT, direction: ASC}): FooConnection!
}

type Foo {
id ID
}

type FooConnection {
edges [FooEdge]
  pageInfo: PageInfo!
}

type FooEdge {
  cursor: String!
  node: Foo
}

query

query {
    hoge {
        foos {
            edges{
                node {
                    id
                }
            }
        }
    }
}

when

func (r *hogeResolver) Foos(first *int, after *string, orderBy *model.SubscriptionOrder) (*model.FooConnection, error) {
	fmt.Println(first, after, orderBy)
	return nil, nil
}

// output

1000 <nil> &{CREATED_AT ASC}

versions

  • gqlgen version? v0.10.2-dev
  • go version? 1.13.7
@Yamashou
Copy link
Author

Yamashou commented Feb 6, 2020

Sorry I can get it !

@Yamashou Yamashou closed this as completed Feb 6, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant