-
-
Notifications
You must be signed in to change notification settings - Fork 267
Custom query variable names #1
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
Comments
When I was trying to get an eager loading graphql library working, I came up with the following:
This is the whats happening inside Slightly altered it to fit your needs, so I havent tested it. Anyway, then its just a matter of adapting the rest to plumb the arguments in... I'm going to play around tomorrow & see what I can do! |
Hi, it seems I've already fixed the problem, but forgot to close the issue. Thanks for trying to help though :) |
Reported by phpstan: Parameter #1 $schema of method Rebing\GraphQL\GraphQL::getSchemaConfiguration() expects array|string, array|string|null given
…elds Reported by phpstan: Parameter #1 $field of static method Rebing\GraphQL\Support\SelectFields::addFieldToSelect() expects string, int|string given.
Reported by larastan: Parameter #1 $name of method Rebing\GraphQL\Support\Type::getFieldResolver() expects string, int|string given
Reported by larastan: Parameter #1 $name of method Rebing\GraphQL\Support\Type::getFieldResolver() expects string, int|string given
…Command::setLaravel() expects Illuminate\Contracts\Container\Container, Illuminate\Foundation\Application|null given"
This was run to fix https://github.com/rebing/graphql-laravel/actions/runs/14163339317/job/39672300001 ``` Line src/GraphQL.php ------ ------------------------------------------------------------------------------------------------------------------------------------------- 259 Parameter #1 $type of static method GraphQL\Type\Definition\Type::nonNull() expects (callable(): (GraphQL\Type\Definition\NullableType&GraphQL\Type\Definition\Type))|(GraphQL\Type\Definition\NullableType&GraphQL\Type\Definition\Type), GraphQL\Type\Definition\Type given. 🪪 argument.type ``` but it seems phpstan also changed the internal format
Currently the variable names have to exactly match the argument names.
Valid: query($id:Int){user(id:$id){...
Invalid: query($userId:Int){user(id:$userId){...
The text was updated successfully, but these errors were encountered: