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
A Completely Unbiased Showcase of Elixir
Search
Andrea Leopardi
September 09, 2016
Programming
2
370
A Completely Unbiased Showcase of Elixir
Andrea Leopardi
September 09, 2016
Tweet
Share
More Decks by Andrea Leopardi
See All by Andrea Leopardi
gen_statem - OTP's Unsung Hero
whatyouhide
2
250
The World is a Network (and We Are Just Nodes)
whatyouhide
1
220
BEAM: The Perfect Fit for Networks
whatyouhide
1
200
Update from the Elixir team - 2022
whatyouhide
0
410
Testing Asynchronous OTP
whatyouhide
1
520
Elixir Sightseeing Tour
whatyouhide
0
430
Mint - Disrupting HTTP clients
whatyouhide
0
250
BEAM Architecture Handbook
whatyouhide
7
2.8k
The Evolution of a Language
whatyouhide
0
160
Other Decks in Programming
See All in Programming
なぜあなたのオブザーバビリティ導入は頓挫するのか
ryota_hnk
0
360
バイブスあるコーディングで ~PHP~ 便利ツールをつくるプラクティス
uzulla
1
260
Yes, You Can Work on Rails & any other Gem
kaspth
0
110
DMMを支える決済基盤の技術的負債にどう立ち向かうか / Addressing Technical Debt in Payment Infrastructure
yoshiyoshifujii
4
580
QA x AIエコシステム段階構築作戦
osu
0
130
CDK引数設計道場100本ノック
badmintoncryer
2
560
テスト駆動Kaggle
isax1015
1
870
Workers を定期実行する方法は一つじゃない
rokuosan
0
130
テストから始めるAgentic Coding 〜Claude Codeと共に行うTDD〜 / Agentic Coding starts with testing
rkaga
16
6k
構造化・自動化・ガードレール - Vibe Coding実践記 -
tonegawa07
0
140
テスト環境にCDを導入してみた
yasaigaoisi
0
100
効率的な開発手段として VRTを活用する
ishkawa
1
180
Featured
See All Featured
Unsuck your backbone
ammeep
671
58k
Designing for Performance
lara
610
69k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
33
2.4k
The Art of Programming - Codeland 2020
erikaheidi
54
13k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
PRO
21
1.3k
The Language of Interfaces
destraynor
158
25k
Done Done
chrislema
184
16k
What’s in a name? Adding method to the madness
productmarketing
PRO
23
3.6k
Become a Pro
speakerdeck
PRO
29
5.4k
The Cost Of JavaScript in 2023
addyosmani
51
8.6k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
10
990
Into the Great Unknown - MozCon
thekraken
40
1.9k
Transcript
UNBIASED A COMPLETELY SHOWCASE OF ELIXIR
None
L F E OVEABLE, UN RLANG
ERLANG FOR HIPSTERS 2.0?
javascript/coffescript java/clojure javascript/elm
javascript/coffescript java/clojure javascript/elm ✓
.BEAM
1.0 September 2014 1.3 September 2016
GOOD STUFF IMPROVABLE STUFF ELIXIR + ERLANG
@whatyouhide
FOOTBALL ADDICTS
GOOD STUFF IMPROVABLE STUFF ELIXIR + ERLANG
GOOD STUFF IMPROVABLE STUFF ELIXIR + ERLANG
STANDARD LIBRARY
STREAMS
STREAMS "foo.txt" |> File.stream! |> Stream.map(...) |> Stream... |> Enum.to_list
METAPROGRAMMING
defmacro unless(cond, expr) do quote do if !unquote(cond) do unquote(expr)
end end end
defmacro unless(cond, expr) do quote do if !unquote(cond) do unquote(expr)
end end end
STRUCTS "official" data types
defmodule User do defstruct [:name, :age] end %User{name: "Meg", age:
33}
PROTOCOLS
JSON encoding json:encode({user, ...}) user:encode({...})
JSON encoding defprotocol JSON do def encode(_) end defimpl JSON,
for: User do def encode(user), do: ... end
ExUnit test "send/2" do send(self(), {:ok, 1}) assert_receive {:ok, _}
end
ExUnit test "send/2" do send(self(), {:ok, 1}) assert_receive {:ok, _}
end
tagging diff --stale
None
--stale don't run stale stinky tests
INTEROP WITH ERLANG for doing Real Work™
lists:map(fun(X) -> X + 1 end, [1, 2, 3]) :lists.map(fn(x)
-> x + 1 end, [1, 2, 3])
Enum.shuffle([1, 2, 3]) 'Elixir.Enum':shuffle([1, 2, 3])
MIX
DOCUMENTATION @doc """ Performs command """ def command(c), do: ...
DOCUMENTATION
ONBOARDING Getting Started guide Resources (books, ...) Error messages
ECOSYSTEM Phoenix Nerves Ecto, Plug, GenStage, ...
COMMUNITY
GOOD STUFF IMPROVABLE STUFF ELIXIR + ERLANG
DIALYZER
PROPERTY-BASED TESTING
USING ELIXIR FROM ERLANG
GOOD STUFF IMPROVABLE STUFF ELIXIR + ERLANG
just an app
WHICH ONE DO I USE ELIXIR ELIXIR ELIXIR ELIXIR ELIXIR
ELIXIR ELIXIR
APPRECIATE BOTH
POSSIBLE RULE OF THUMB libraries in Erlang (if they wouldn't
benefit from Elixir features) apps in Elixir /
hex.pm Erlang + Elixir
GOOD STUFF IMPROVABLE STUFF ELIXIR <3 ERLANG STDLIB EXUNIT METAPROGRAMMING
PROTOCOLS MIX DOCS ECOSYSTEM DIALYZER PROPERTY-BASED TESTS ELIXIR FROM ERLANG USE BOTH SHARE ON HEX BE NICE
@whatyouhide