Ingest Files

Statically importing files as a Str or a List U8 (list of bytes):

import "some-file" as someStr : Str
import "some-file" as someBytes : List U8


app [main] { pf: platform "" }

import pf.Stdout
import pf.Task
import "sample.txt" as sample : Str

main =
    Stdout.line! "$(sample)"


Run this from the directory that has main.roc in it:

$ roc run main.roc
The quick brown fox jumps over the lazy dog