Scaladoc 3 static site

I’ve been reading and trying to use scaladoc to build a static site, without success. Anyone has a full working example, including sbt config? I’m having a hard time figuring out what file should go where, and what options are necessary (none of my markdown or html is being picked up).


Here is a simple example:

The is placed on top in the docs folder,as configured in this part of the build.sbt:

Compile / doc / scalacOptions ++= Seq(
  "-project-version", Version,
  "-project-footer", "Dep. of Computer Science, Lund University, Faculty of Engineering LTH",
  "-siteroot", ".",
  "-doc-root-content", "./docs/",

The generated docs are here:



Incidentally, what I’m creating is also a course support library (though more for me than for the students). I’m currently using the department’s web server as a repository, but I’d like to push it to GitHub or Maven at some point. I’ll probably need some help on that too…

I used your example as a starting point, and did a little more digging. Two sources of confusion for me were:

  • You use the same file for the root documentation of the API and and the root documentation outside the API. There’s no law against that, but one can also use two different files.
  • Contrary to what the scaladoc manual says, the default value for siteroot is ".", not "docs".

In the end, I wrote a small demo, with an sbt configuration and a few markdown files, that others might find useful as a starting point:

The output looks like this:


Thank’s for sharing! That’s really useful! I’ll take a look eventually how to update my stuff to perhaps be more as intended…