DEV Community

Jess Lee
Jess Lee Subscriber

Posted on

Why might I want to learn Elixir?

Top comments (10)

Collapse
 
niharmore33 profile image
nihar

I’m learning Elixir and I find it really great. I’ve been doing Ruby (and some other things) in the last 8 years and it is the language I like the most. Elixir comes with a great syntax and makes me feel comfortable when writing it.
Best Elixir tutorials recommended by programming community: hackr.io/tutorials/learn-elixir

Is it easy as Ruby on Rails?

Hm, that’s a strange comparison. But if you want to do web applications, I highly recommend you to check out Phoenix. In case you’re already doing Rails, it will not be so weird for you. They are not the same, but some concepts on Phoenix were inspired on Rails.

Hows the job offering these days?

Elixir is still in the early adopters phase, which means that you’ll be investing on Elixir future. I’m a big fan of being an early adopter (not so early, but…) because you’ll have the opportunity to build new things and help the community grow. But it’s a bet and has it’s risks. You may want to work with Java, it has many job offers available, but it’s not for me.

What can I build using Elixir?

Everything you want. For some of them, Elixir will be great and it will not be the best tool for others.

You want to build your own blog, for example. You may use Elixir to create it, but there are many other tools that will suite better for this case.

Collapse
 
diveshjain25 profile image
DIVESH SANKHLA

Elixir is one of the best language functional language according to me. Your link content various good elixir tutorials also check letsfindcourse.com/elixir

Collapse
 
joshcheek profile image
Josh Cheek

Because you use Ruby but want to learn Erlang. Why do you use Ruby but want to learn Erlang? Because you're using Rails to write web services and you're hitting performance bottlenecks and reliability issues and going to tremendous effort to optimize and add infrastructure. But instead of taping a rock to the end of your screwdriver, you could just use a hammer.

Collapse
 
billperegoy profile image
billperegoy

I initially was drawn to it because it provided a low barrier entry point to functional programming. The syntax looked a lot like Ruby and it focused on the concept of functions rather than more esoteric functional concepts. Then combining it with Phoenix gave me a Rails-like framework but with less metaprogramming magic and a more explicit approach. I think the real game changer (which I've yet to use) is OTP. It looks like an incredibly powerful methodology for building reliable, distributed applications.

Collapse
 
bobbypriambodo profile image
Bobby Priambodo

Language extensibility via macros. Elixir has metaprogramming features, but don't let that discourage you! Elixir's macros allows libraries to define new constructs for particular domains. If used correctly, macros enable highly readable code. Great examples are the use of macros in Phoenix web framework, Ecto (Elixir's kind-of-ORM, the macros allows you to write fluent queries in a beautiful syntax), and ExUnit (Elixir's builtin test framework).

Tooling integrated to the core. We have Mix, a build tool that allows us to easily create projects, compiling, run tasks and tests, and other typical stuff. There's also Hex package manager to resolve and fetch dependencies. ExUnit is also nice to set up test suites in a jiffy.

However, probably the most compelling reason is that you get to use the niceties of Erlang VM and OTP to build concurrent, distributed, and fault-tolerant systems. Think hot code reloading, zero-downtime upgrades, and 99.9999999% (nine nines) reliability. pragprog.com/articles/erlang

Collapse
 
rainteller profile image
rainteller

Pipe operator? :]

Collapse
 
oscherler profile image
Olivier “Ölbaum” Scherler

Fine, but why might I want to learn Elixir over Erlang?

Collapse
 
jveiga profile image
João Veiga

Familiarity, if you are using languages like ruby, javascript, etc, you will find it easier to understand Elixir.
Elixir also has some high level libraries, Enum, Stream, GenStage, Agents, Tasks.
It's nothing that you can't do in Erlang, you would just have to create it by yourself.
Great tooling with Mix.

Just off the top of my head :)

Collapse
 
chrispickard profile image
Chris Pickard

The tooling story is light years better