3 ms·
Thanks for sharing the project. I learned a few nice patterns like returning a specialized handler module from a dispatcher function.
by bodgix 6y ago
Thanks for sharing the project. I learned a few nice patterns like returning a specialized handler module from a dispatcher function.
- QuinnWilton 6y agoI'm glad you enjoyed it! Some of these patterns are a little controversial, because they add extra layers of indirection + bloat the code, but I've personally always found that they make Erlang / Elixir much more readable. One of my favourite talks is "Writing Beautiful Code" by Garrett Smith (of "MongoDB is Web Scale" fame), and he walks through refactoring a part of CouchDB (also in Erlang) by using some of these techniques. https://www.youtube.com/watch?v=IdJwECjylB4 https://www.youtube.com/watch?v=IdJwECjylB4