by Example

Elixir


An elegant, thoughtful, concurrent & fault tolerant programming language



Elixir is a functional, compiled, dynamically typed programming language, designed for buliding scalable and maintainable networked applications.

Elixir targets the Erlang VM, and it compiles down to same BEAM bytecode Erlang does, so Elixir can freely call Erlang code, and vice-versa.

Elixir is not just a programming language. It includes novel libraries, an excellent package manager and build tool (mix).

Tools —  elixir (script runner), elixirc (compiler), iex (interactive shell) and mix (project management)

Code — a collection of expressions form a module, and a collection of modules form an app

Tools

mix is Elixir's default project management tool

$ mix new project_name

Create a new library project

$ mix new --sup project_name

Create a new supervised, `startable` application project

$ iex -S mix

Start application at current directory, then enter its interactive shell