Hi, I want to tackle this https://github.com/roc-lang/roc/issues/5106 if no one is working on it already. Just a question: How would I build the docs to test it locally? I did cargo run --bin roc-docs
, but it errored with it couldn't find main.roc. :thinking:
Hi @itmuckel,
The tutorial is separate from the docs, you can build the tutorial by following the instructions in the README here.
Feel free to ask additional questions or make suggestions for how we can improve contributor-oriented documentation :)
For the tutorial specifically I think you need to be on http://0.0.0.0:8000/tutorial
This folder will probably be where you want to make some changes to implement your issue.
Oh, I think the issue is a bit missleading? The linked discussion on zulip is about the clickable function names in the docs for the stdlib that should not be clickable but instead have an svg on hover
Oh yeah, that should be for the docs, it doesn't really make sense for the tutorial.
So this is the error message, but I'd need to build roc-docs to build the docs, right?
$ cargo run --bin roc-docs
Compiling roc_docs_cli v0.0.1 (/home/itmuckel/Code/roc/roc/crates/docs_cli)
Finished dev [unoptimized + debuginfo] target(s) in 16.11s
Running `target/debug/roc-docs`
── FILE NOT FOUND ──────────────────────────────────────────────── UNKNOWN.roc ─
I am looking for this file, but it's not there:
main.roc
Is the file supposed to be there? Maybe there is a typo in the file
name?
Oh, now I get it, roc-docs needs a target and I'm not providing one :-D
In www/build.sh you can also find the build steps we use for the documentation. I recommend searching for builtins
in that file to find the relevant steps.
is jq missing in the nix environment of develop?
$ ./build.sh
+ jq --version
./build.sh: line 7: jq: command not found
Yes, I didn't know about that, you can add jq
below wasm-pack
in flake.nix
. You may then need to do exit
followed by nix develop
to load the updated file
Alright, thanks, I got it working. :-)
https://github.com/roc-lang/roc/pull/5132 it ain't much, but it's honest work :sweat_smile:
We all start small :)
I'll do the review
Wait, I spotted a mistake :')
Okay, removed the useless class and rebased, now it looks fine :)
Where do I submit a bug report for https://www.roc-lang.org/tutorial#lists-that-hold-elements-of-different-types?
Can just add a new issue here: https://github.com/roc-lang/roc/issues/
Last updated: Jul 05 2025 at 12:14 UTC