Devon C. Estes devonestes.herokuapp.com

A proposal for some new rules for Phoenix contexts  ↦

Phoenix 1.3 introduced the idea of Contexts, which I’m generally very much in favor of. However, I wish there was a little bit more structure to the idea. It’s so open ended that I’ve found deciding where best to put a function kind of tricky, and then I frequently end up with duplicate behavior across contexts or have a hard time finding functions later on because the module they’re in made sense at the time, but it doesn’t make as much sense now.

So, I’m proposing the idea of a Primary Context and a Secondary Context.

I’ve also struggled to determine just how to use Contexts to my benefit. It seems that Devon is trying an add more structure approach whereas I have (so far) gone with a YAGNI approach.


Discussion

Sign in or Join to comment or subscribe

0:00 / 0:00