Skip to content
Permalink
Browse files

## Minimum Viable Elixir

Starting at the beginning, we need to recognize that all Phoenix applications are Elixir applications. Our first step in the process of building a minimum viable Phoenix application is really to build a minimum viable Elixir application.

Interestingly, the simplest possible Elixir application is simply an `*.ex` file that contains some source code. To set ourselves up for success later, let’s place our code in `lib/minimal/application.ex`. We’ll start by simply printing `"Hello."` to the console.

	IO.puts("Hello.")

Surprisingly, we can execute our newly written Elixir application by compiling it:

	➜ elixirc lib/minimal.ex
	Hello.

This [confused me at first](https://twitter.com/petecorey/status/1122629600800989184), but it was explained to me that in the Elixir world, [compilation is also evaluation](https://twitter.com/Di4naO/status/1122944924989706240).
  • Loading branch information...
pcorey committed May 6, 2019
1 parent 6f8c9d8 commit 4e2e319595415ff66fdc18679547ac49247979e7
Showing with 1 addition and 0 deletions.
  1. +1 −0 lib/minimal/application.ex
@@ -0,0 +1 @@
IO.puts("Hello.")

0 comments on commit 4e2e319

Please sign in to comment.
You can’t perform that action at this time.