jlouis / graphql-erlang

GraphQL implementation in Erlang.
Other
313 stars 52 forks source link

GraphQL with Yaws #208

Open navneetixz opened 5 years ago

navneetixz commented 5 years ago

Does anyone have an example tutorial of GraphQL with yaws? Or some leads, hints is appreciated.

leoliu commented 5 years ago

You need an appmod which is basically an erlang module with out/1 exported. The module should catch the request, get the body, query strings etc and pass them to graphql similar to the cowboy tutorial. Unlike cowboy Yaws doesn't have a builtin REST flow.