Best Practices to code design on a graphql API using Contexts?

Hi, I’ve research on the internet and I didn’t found articles about best practices to create projects (web site, Api, micro services) with phoenix.

Do you guys have a suggestion about best practices?

My project is a graphql API and I’m structuring my code using phoenix contexts ( https://hexdocs.pm/phoenix/contexts.html#content ). However, organizing the code just using context seems a “cat basket”. On the github, I’ve found some 4 phoenix projects which they had 7, 8 contexts. The folder ‘lib/MODULE_NAME’ seems a mess up.

When a code with Rails, Symphone or even GO, I have services class, business class, model class, decorators class using SOLID, LOD, DRY and other good code patterns

To get started:

2 Likes