purescript-graphql
purescript-graphql copied to clipboard
Allow to change the context in subfield through resolver
In theory we could allow to change the context of child fields. This might be possible by adjusting withResolver so that the resolver could switch the context. I think this is wrong but maybe it conveys the idea:
- withResolver :: forall m a b argsd argsp.
+ withResolver :: forall m n a b argsd argsp.
MonadError Error m =>
- Field n a argsd argsp ->
+ Field n a argsd argsp ->
(Record argsp -> b -> m a) ->
Field m b argsd argsp
I can't really think this through right now, but maybe some ideas come up...