What's your preferred granularity of docs?
(a) A whole module on one page, e.g. https://pkg.go.dev/time, making search easy?
(b) A function per page, e.g. https://www.php.net/manual/en/function.time.php, giving more space for examples and See Also sections?
I'm torn, and I've seen both done well.
miniblog.
Related Posts
I'm experimenting with syntax in examples. I don't really like Rust's `assert(inc(1) == 2)` syntax, I find it a little distracting.
I'm trying `inc(1) //-> 2`. The comment is rendered differently, and there's nothing before the sample code. What do you think?
Go has an elegant approach to defining example functions, which are shown in docs as `main()` with the output:
Some delightful examples of good compiler error messages in the latest Gleam release:


