Created
March 1, 2018 00:36
-
-
Save smoak/71edc31bc7296cc811c9fe5d8f4447a6 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
defmodule Schema do | |
use Absinthe.Schema | |
object :user do | |
field :id, non_null(:id) | |
end | |
object :viewer do | |
field :user, non_null(:user) do | |
resolve(fn _parent, _args, _ctx -> | |
IO.puts("resolving user") | |
{:ok, nil} | |
end) | |
end | |
end | |
query do | |
field :viewer, :viewer | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment