by sgadimbayli on 5/20/20, 5:58 PM with 132 comments
by biggestlou on 5/20/20, 6:58 PM
But there are some great language features, like guards and pattern matching, that are hard to give up when you go back to other languages.
Plus it's great to have OTP goodies like GenServer at your fingertips if you run into performance bottlenecks (which you may not!). The OTP APIs are a bit weird coming from other languages but not too bad.
Other things I've liked:
1. Ecto is simply the best DB library I've encountered in any language. I'd almost recommend learning Elixir just to be able to use Ecto.
2. Plug provides great HTTP ergonomics highly reminiscent of Go's context-based middleware approach. Having direct access to the full request/response lifecycle is a win.
3. Phoenix is nice because it's essentially just Plug with some convenient helpers on top. Strikes a really nice balance between configuration and convention by letting you use only what you need. Haven't tried LiveView as I'd prefer to handcraft my own JS but probably worth a shot.
4. Absinthe is the best GraphQL framework I've encountered after many others in other languages left me completely cold.
by ashton314 on 5/20/20, 7:09 PM
https://stackoverflow.com/questions/32085258/how-can-i-sched...
So simple. Something that would require a job queue and a job runner fades away into a piece of the OTP application tree. When it crashes, it will even come right back up!
Phoenix feels a little too heavyweight for really small projects—maybe I'm spoiled having used Mojolicious's [0] single-file web servers. (Example on the linked page.) But for anything slightly larger, Phoenix scales really well. I work on a decently-large application in Phoenix for work and it's been an absolute joy to work with this langauge.
Typing could be better. Though, Dialyzer does a decent job of catching type errors. That's saved my neck on more than one occasion.
by ninjakeyboard on 5/20/20, 6:35 PM
It's a great path for rubyists to move to Elixir/BEAM and every rubyist should give it a whirl! I'm back working on scala and akka.
by namelosw on 5/21/20, 12:13 AM
On the other hand, it also reflects functional programming is also more straightforward than Object-oriented programming because it's more objective to just model the data, than modeling the data and procedures at the same time. If you have two people writing the same thing, there's a much larger chance they'll yield similar or identical results.
by mostlysimilar on 5/20/20, 6:20 PM
I would love to find a job doing it.
by crusso on 5/20/20, 6:35 PM
For a while I was using Phoenix<>Elm as my stack and I enjoy programming in Elm. But there's a lot of boilerplate you have to tediously connect for every input and output on both sides of the server and client.
LiveView eliminates all that boilerplate by letting you write templates in Elixir that are macro-compiled to javascript. Getting rid of that boilerplate eliminates time writing it as well as time debugging the extra complexity that boilerplate introduces.
by ketzo on 5/20/20, 6:29 PM
Working with Elixir is really cool, too, coming from C++ & JS backgrounds. Pattern matching feels like a programming technique from the future.
by adamzapasnik on 5/20/20, 8:05 PM
Btw. If anyone is interested, I'm working on prettier plugin for html l?eex files. Probably gonna publish it next week.
by fredwu on 5/20/20, 11:35 PM
The first piece is longer, on my journey learning Elixir and building machine learning libraries.
https://fredwu.me/blog/2016-07-24-i-accidentally-some-machin...
The second piece is shorter, on Elixir’s functional aspect and how doctest changes the way I code.
https://fredwu.me/blog/2017-08-07-elixir-and-doctest-help-wr...
by aloukissas on 5/20/20, 11:40 PM
by ldd on 5/21/20, 12:23 AM
MIT Licensed. Source:
by aloukissas on 5/20/20, 6:13 PM
by peruvian on 5/20/20, 6:25 PM
by sjm on 5/20/20, 8:56 PM
by jonnycat on 5/21/20, 12:42 AM
Curiously, unlike most others here, I'm not completely loving Ecto. I appreciate the philosophy and get changesets, but I'm finding the query syntax clumsy.
by jetpackjoe on 5/20/20, 7:22 PM
by pmarreck on 5/21/20, 4:42 AM
https://ekarak.com/2020/05/16/of-elixir-phoenix-and-analogie...
by throwaway286 on 5/21/20, 12:52 AM
by flowers111 on 5/21/20, 7:37 AM
by Thaxll on 5/20/20, 6:41 PM