Hello gain, the tutorial says this code will work:
{ height, width, title ? "", description ? Str.concat "A table called " title }
I wrote the following;
main = Stdout.line "$(table {height: 3, width: 2})"
table = \{height, width, title ? "", description ? Str.concat "Table name: " title} ->
"Table: $(Num.toStr height) x $(Num.toStr width) $(description)"
and am getting this error:
── UNRECOGNIZED NAME in main.roc ───────────────────────────────────────────────
The #UserApp module does not expose anything by the name title.
────────────────────────────────────────────────────────────────────────────────
1 error and 0 warnings found in 185 ms.
any feedback as to what's going wrong?
I'm pretty sure the tutorial is ahead of the language and we should remove that from the tutorial until we add the feature.
Thank you for your swift response
Last updated: Jul 06 2025 at 12:14 UTC