graphql icon indicating copy to clipboard operation
graphql copied to clipboard

executor: adds support for anonymous contained structs

Open chris-ramon opened this issue 5 years ago • 15 comments

Overview

  • Built on top of: https://github.com/graphql-go/graphql/pull/274
  • closes: https://github.com/graphql-go/graphql/issues/170

Test plan

  • go test ./...

chris-ramon avatar Jul 28 '18 17:07 chris-ramon

HI, wondering if there is any chance to merge this?

imjma avatar Sep 14 '18 05:09 imjma

@chris-ramon @pavelnikolov Same question, would you please merge it?

mrg0lden avatar Oct 19 '18 22:10 mrg0lden

Same here

niondir avatar Oct 22 '18 20:10 niondir

Thanks for letting us know how important this PR are for you guys.

I'll jump back to get this merge as soon as I get the chance today/tomorrow.

chris-ramon avatar Oct 22 '18 20:10 chris-ramon

Coverage Status

Coverage increased (+0.009%) to 91.787% when pulling d35d558066e2ec602528a5db16f29e9cd06173de on anon-contained-struct into a7e15c0298411af18c694ca387e733acef287104 on master.

coveralls avatar Oct 24 '18 00:10 coveralls

I think this will resolve the issue without using user-provided resolve function.

if typeField.Anonymous && typeField.Type.Kind() == reflect.Struct {
  anonymousResolvedValue, err := defaultResolveStruct(valueField, fieldName)
  if err != nil {
    return nil, err
  } else if anonymousResolvedValue != nil {
    return anonymousResolvedValue, nil
  }
}

raininfall avatar Nov 12 '18 14:11 raininfall

Just commented on the issue, but just saw this PR. I'm still interested in this!

abraithwaite avatar Mar 04 '19 16:03 abraithwaite

Any news on this ?

clery avatar Apr 01 '19 09:04 clery

Any updates on this PR?

cettoana avatar May 30 '19 04:05 cettoana

Still waiting for the merge as qell...

niondir avatar Jun 13 '19 16:06 niondir

This PR has conflicts.

pavelnikolov avatar Jun 13 '19 22:06 pavelnikolov

Is this still being worked on?

SuNNjek avatar Aug 26 '20 08:08 SuNNjek

Not that I am aware of

pavelnikolov avatar Aug 26 '20 11:08 pavelnikolov

Hi how to use this feature on graphq-go/graphql v0.8.0 (master branch)? about Anonymous(embed) struct

bakatest-me avatar Jun 23 '22 07:06 bakatest-me

Bump

taleeus avatar Mar 20 '24 11:03 taleeus