I’ve recently started writing a series of posts on setting up a GraphQL backend in Phoenix. I figured I’d share them here for those that may be interested in alternative backends that can be consumed with Apollo Client. You could probably follow along even if you’ve never used Elixir or Phoenix since I walk through setting everything up.
First post: Setting up the API and learning to query it with GraphiQL
Second post: Adding CRUD functionality with mutations
Third post: Adding authentication
Right now the team behind the Absinthe GraphQL library is getting ready to release a library that will work with Phoenix generators. So, adding a GraphQL resource would be as simple as running something like:
$ mix phoenix.gen.graphql User users name:string email:string password:string
How’s that for no boilerplate! Exciting stuff.
In the future I’ll be writing a post on consuming the GraphQL API I build in the posts with Apollo Client. I’m happy to answer any questions that you have if you’re interested in looking into Elixir or Phoenix. Right now is a great time to jump in.