Skip to content

Instantly share code, notes, and snippets.

@velotiotech
Created June 11, 2020 07:34
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Embed
What would you like to do?
pipeline :graphql do
plug Graphql.Context #custom plug written into lib/graphql_web/plug/context.ex folder
end
scope "/api" do
pipe_through(:graphql) #pipeline through which the request have to be routed
forward("/", Absinthe.Plug, schema: GraphqlWeb.Schema)
forward("/graphiql", Absinthe.Plug.GraphiQL, schema: GraphqlWeb.Schema)
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment