mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-27 13:59:08 +00:00

Implements the new app header syntax as discussed in Zulip [1].
app [main] {
cli: platform "../platform/main.roc",
json: "../json/main.roc"
}
Old headers still parse and are automatically upgraded to the new
syntax by the formatter.
[1] 418444862
16 lines
433 B
Text
16 lines
433 B
Text
app [main] { pf: platform "effects-platform/main.roc" }
|
|
|
|
import pf.Effect
|
|
|
|
main : Effect.Effect {}
|
|
main =
|
|
Effect.after
|
|
(Effect.getLine)
|
|
\line ->
|
|
Effect.after
|
|
(Effect.putLine "You entered: $(line)")
|
|
\{} ->
|
|
Effect.after
|
|
(Effect.putLine "It is known")
|
|
\{} ->
|
|
Effect.always {}
|