Elixir Moments

Share things relating to Elixir that put a smile on your face :003:

https://twitter.com/erdemgezer/status/709458806883876865

15 Likes

Am I missing something? Something important? Like context?

It’s just a common thing people say about other languages (that they don’t scale very well) and obviously Elixir can :003:

Argh, damn
 The words “No-one, Ever” below were misinterpreted as a subtitle by me. Only now I realise, that it is meant to be the person who said this and the date of the quote. So it is meant like this: “Elixir doesn’t scale.” said No-one, ever.

5 Likes
  def get_available_internal_users do
    user_coll = from(u in User, 
                     select: {u.name, u.role, u.id},
                     where:  u.role != "Client") |> Repo.all

    for {name, role, id} <- user_coll, into: %{}, do: {{name, role}, id}
  end  

Just wrote this function to get all users from my project’s DB which do not have the role of ‘Client’ and put their name, role and id into a map.

Such nice, concise and readable code.

First I was doing a lot of List.first/1 and List.last/1 and Tuple.to_list/1 to get the values into the map. Then it came to me “why not just pattern match the tuple and use the matches to get them into the Map?” and boom
 that code came to fruition :slight_smile:

Honestly can’t think of any other language that would allow me to query a SQL DB, parse the data and make it all so readable and short. There isn’t a need to write comments really, it reads by itself.

11 Likes
1 Like

https://twitter.com/erlangfactory/status/726059859095875585?refsrc=email&s=11

:023:

Tomorrow is orthodox Easter, so I painted eggs, and this one reminded me of Elixir logo :slight_smile:

9 Likes

https://twitter.com/chris_mccord/status/727267197798744064

16 Likes

https://twitter.com/chris_mccord/status/730291435145146368

8 Likes

Awesome , I have become an elixir talk junkie since I started with elixir & erlang
cant wait for more talks on the tube

2 Likes
3 Likes

Via @rvirding :lol:

11 Likes

Hah. Favorite line:

I believe in Erlang, where I get to use concurrency

1 Like

I love this video!

2 Likes

:003:

2 Likes

:purple_heart:

4 Likes

https://twitter.com/devoncestes/status/910411735458308096

By @devonestes

Well done all of you who make this the friendly, welcoming and helpful place that it is :purple_heart:

4 Likes

By @cmeiklejohn

3 Likes

6 posts were split to a new topic: Your Programming Heroes - please post pics and stories!