update
Former-commit-id: bdede6ed1b6f578f2ef046c338caf02d0b29d453 [formerly 7187de361b53e9c8ec121df379b762f2db736ea2] Former-commit-id: 447d58460fbbfd05ffe08428a1288e392637561d
This commit is contained in:
42
_embed/public/ace/demo/kitchen-sink/docs/elixir.ex
Normal file
42
_embed/public/ace/demo/kitchen-sink/docs/elixir.ex
Normal file
@@ -0,0 +1,42 @@
|
||||
defmodule HelloModule do
|
||||
@moduledoc """
|
||||
This is supposed to be `markdown`.
|
||||
__Yes__ this is [mark](http://down.format)
|
||||
|
||||
# Truly
|
||||
|
||||
## marked
|
||||
|
||||
* with lists
|
||||
* more
|
||||
* and more
|
||||
|
||||
Even.with(code)
|
||||
blocks |> with |> samples
|
||||
|
||||
_Docs are first class citizens in Elixir_ (Jose Valim)
|
||||
"""
|
||||
|
||||
# A "Hello world" function
|
||||
def some_fun do
|
||||
IO.puts "Juhu Kinners!"
|
||||
end
|
||||
# A private function
|
||||
defp priv do
|
||||
is_regex ~r"""
|
||||
This is a regex
|
||||
spanning several
|
||||
lines.
|
||||
"""
|
||||
x = elem({ :a, :b, :c }, 0) #=> :a
|
||||
end
|
||||
end
|
||||
|
||||
test_fun = fn(x) ->
|
||||
cond do
|
||||
x > 10 ->
|
||||
:greater_than_ten
|
||||
true ->
|
||||
:maybe_ten
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user