Skip to content

Conversation

Cryt1c
Copy link
Contributor

@Cryt1c Cryt1c commented Jun 24, 2022

There was a full working example requested here:
#1288

There was a full working example requested here:
drupal-graphql#1288
@joaogarin joaogarin requested a review from klausi July 8, 2022 06:00
Copy link
Contributor

@klausi klausi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, just some whitespace issues that should be cleaned up!

(For this to actually work we would need to add resolvers to the User object to resolve the `id` and `name` properties).
For this to actually work we would need to add resolvers to the User object to resolve the `id` and `name` properties like so:
```php
$registry->addFieldResolver('User', 'id', $builder->callback(function ($account) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

any reason for the indentation here? We don't have it in the field resolver examples further above.

@klausi
Copy link
Contributor

klausi commented Jul 13, 2022

I can merge this anyway and fix the whitespace in a follow-up.

@klausi klausi merged commit 81bcdad into drupal-graphql:8.x-4.x Jul 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants