Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
what is this elixir thing everyone is talking a...
Search
José Tomás Albornoz
September 16, 2016
Programming
160
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
what is this elixir thing everyone is talking about
some of my fav features of elixir
lightning talk for CodeDaze.io on September 16th, 2016
José Tomás Albornoz
September 16, 2016
More Decks by José Tomás Albornoz
See All by José Tomás Albornoz
Things I learned when working on a small startup
eljojo
0
100
Introduction to Dokku
eljojo
1
170
Baruco 2014: How I Built My Own Twitch-Plays-Pokémon
eljojo
0
1.1k
Introduction to Docker
eljojo
0
260
Other Decks in Programming
See All in Programming
FastAPI の並行処理モデルを完全に理解する
hoto17296
9
3.4k
GKE アップグレード前に知っておきたい Blue/Green と PDB の関係
stkk
0
130
不幸な GC
chencmd
0
860
Swift愛好会と私(ウホーイ) / Swift Fan Club and Uhooi
uhooi
0
120
tsc.rip を支える技術 / Kyoto.なんか #8
susisu
0
4.2k
이 함수, 실패하면 어떻게 되나요? null부터 Rich Errors까지, Kotlin 에러 처리 15년
haeti2
0
110
Go 1.27 における memory allocation の高速化
andpad
0
370
初めての模倣学習とVLA
natsutan
0
410
AIエージェント時代のコードレビューを設計する
nogu66
5
2.1k
FDEとは、何者なのか?
masapyon1212
0
110
[PyCon KR 2026] More Variants, More Diversity for AI Accelerators
achimnol
0
130
高専キャリア LT 発表内容
crysta1221
6
5.4k
Featured
See All Featured
Efficient Content Optimization with Google Search Console & Apps Script
katarinadahlin
PRO
1
840
Amusing Abliteration
ianozsvald
1
280
The innovator’s Mindset - Leading Through an Era of Exponential Change - McGill University 2025
jdejongh
PRO
1
320
Hiding What from Whom? A Critical Review of the History of Programming languages for Music
tomoyanonymous
3
1.2k
Building Experiences: Design Systems, User Experience, and Full Site Editing
marktimemedia
0
590
Building Better People: How to give real-time feedback that sticks.
wjessup
370
20k
How to build a perfect <img>
jonoalderson
1
5.9k
The agentic SEO stack - context over prompts
schlessera
0
880
Design of three-dimensional binary manipulators for pick-and-place task avoiding obstacles (IECON2024)
konakalab
0
570
The Impact of AI in SEO - AI Overviews June 2024 Edition
aleyda
6
1.2k
Automating Front-end Workflow
addyosmani
1369
210k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
201
75k
Transcript
what is this elixir thing everyone's talking about by jojo
what is elixir
elixir is a functional language
created by José Valim
that runs on the erlang vm
pattern matching iex(1)> [first, second] = [1, 2] [1, 2]
iex(2)> first 1
pattern matching iex(2)> [first, second] = [1,2,3] ** (MatchError) no
match of right hand side value: [1, 2, 3]
pattern matching iex(1)> payload = %{username: "eljojo", stuff: true} %{stuff:
true, username: "eljojo"} iex(2)> %{username: name} = payload %{stuff: true, username: "eljojo"} iex(3)> name "eljojo"
function overloading def make_sound(:cow) do IO.puts "MOOOOOOOOO" end def make_sound(:cat)
do IO.puts "MEEEOOWW" end def make_sound(_) do IO.puts "¯\_(ϑ)_/¯" end
function overloading def make_sound(%{animal: :cow}) do IO.puts "MOOOOOOOOO" end def
make_sound(%{animal: :cat}) do IO.puts "MEEEOOWW" end def make_sound(%{animal: name}) do IO.puts "not sure how to #{name} ¯\_(ϑ)_/¯" end
we also got guards def page_ops(downtime) when downtime < 10
do IO.puts "¯\_(ϑ)_/¯" end def page_ops(downtime) when downtime >= 10 do PagerDuty.notify(whatever) end
pipe operator def add_one(number), do: number + 1 def multiply_by_three(number),
do: number * 3 multiply_by_three(add_one(1)) # => 6
pipe operator def add_one(number), do: number + 1 def multiply_by_three(number),
do: number * 3 1 |> add_one |> multiply_by_three # => 6
processes + messages current_process = self() spawn_link(fn -> send(current_process, {:msg,
"hello world"}) end) receive do {:msg, contents} -> IO.puts contents end
processes + messages # machine one receive do {:msg, contents}
-> IO.puts contents end # machine two process_name = "$MACHINE_ONE" spawn_link(fn -> send(process_name, {:msg, "yo!"}) end)
what is phoenix
A productive web framework that does not compromise speed and
maintainability.
it's basically rails for elixir, but cooler
validations def changeset(struct, params \\ %{}) do struct |> cast(params,
[:email_address, :first_name]) |> validate_required([:email_address]) end def changeset_after_signup(struct, params \\ %{}) do changeset(struct, params) |> validate_required([:first_name]) end
we're hiring!
@eljojo