by colesantiago · 3y ago · 0 comments
Last I checked a while ago Brex famously used to be on Elixir but now are on Kotlin.
https://medium.com/brexeng/building-backend-services-with-ko...
With added LiveView on top, you could avoid writing a lot of SPA react (vue, svelte etc) code (some limitations apply, but you can do a lot), spending less people, time and resources for the same result.
Traditional setup: backend logic + backend api + react SPA + logic for calling backend api
LiveVew setup: phoenix backend + LiveView views + a bit of glue code (in elixir) to replace onclick etc stuff
1. Laravel Livewire for PHP
2. Hotwire for Rails/Ruby
3. Blazor for C#/.NET
4. HTMX* as a general tool for any other web server
5. React Server Components (if you squint hard enough)
Phoenix Liveview definitely started the trend by showing a mature implementation of these ideas on the same level as the application developer.
I would argue number 5 is a bit of a meme, since you still have to write a ton of JS, but if you're more interested in the architecture ideas for structuring your app, there is an interesting parallel that I think can be drawn.
[*] HTMX doesn't really embrace the idea of calling a function from your server by name, but the ergonomics are similar when writing frontend code.
Livewires performance is terrible for anything other than very basic components. The fact that it has to rebuild state on every interaction makes it a pretty poor tool for most use cases.
The syntax reads and writes very well. When I now have to write other languages, mainly Typescript, I miss native pattern matching and the pipe operator.
Whatsapp famously got to 1 billion messages a day with only 11 engineers on the BEAM (the VM that elixir runs on). It has proven itself immensely capable at the highest levels of scale so the only thing for anyone to decide is whether the stdlib and tooling is to their liking (speaking mostly in the context of networked IO bound applications, which is most things on the internet)
People are of course different and I fully acknowledge that things that seem normal to me may seem odd to others, so YMMV.
So you were correct some years ago but I am not seeing this nowadays. So yeah, valid criticism, at the same time this criticism has been mostly taken to heart and addressed as of today.
also, the errors you get, when they are in erlang are in valid erlang, i can't say that about Java, Ruby, Python or PHP which give you errors in English.
https://hackernoon.com/why-is-erlang-the-only-true-computer-...
Fans of Elixir out in force today downvoting dissenting opinions even though its valid.
In almost every lang you'll run into something that your aren't familiar with and you'll have to dive into something you aren't comfortable with. I had to dive into some C code when ruby decided to segfault. I've had to dive into Java JVM internals when working in Clojure.
So I'm not sure this is a "elixir" thing as much as a "I'm a developer thats supposed to know multiple languages and stacks" kinda thing.