effekt-lang / effekt-website

Website of the Effekt programming language
https://effekt-lang.github.io/effekt-website
MIT License
4 stars 6 forks source link

Case study code is incomplete, run button doesn't work, no easy way to copy example code #80

Open osa1 opened 1 week ago

osa1 commented 1 week ago

This is an issue report and feedback at the same time.

Consider this case study: https://effekt-lang.org/docs/casestudies/scheduler

Problems:

In general, it would be helpful if all complete examples in the web site had a link to the full file of the example that can be run locally by copying the entire file.

marvinborner commented 1 week ago

Thanks for the feedback!

The casestudies are actually generated from runnable files which we call literate Effekt. You can run this particular casestudy using effekt.sh examples/casestudies/scheduler.effekt.md (inside the Effekt repository).

Clicking on the "run" button will only cause "Cannot compile interactive.effekt" if you do not call the main() function (you can enter this yourself).

I agree, though, that both of these points could be made a lot more clear. Linking to the literate Effekt file also sounds like a good idea.