5

I cannot add a package description in ScalaDoc with Scala 3

/** package description */
package foo {
    /** some scaladoc comment */
    def method():A = ???
}

Then I generate the doc with sbt (1.5.3)

sbt> doc

I don't get the description of the package itself in the index.html file, but only the description of the method inside the package.

lepaincestbon
  • 331
  • 1
  • 5
  • Maybe it is not possible anymore, as the scala 3 library do not use package comment, and `package object` is becoming deprecated – lepaincestbon Jun 13 '21 at 16:52

1 Answers1

5

I finally found the answer

Scaladoc comments can go before fields, methods, classes, traits, objects. For now, scaladoc doesn't support straightforward solution to document packages. There is a dedicated github issue, where you can check the current status of the problem.

https://github.com/lampepfl/dotty/issues/11284

Karl Bielefeldt
  • 47,314
  • 10
  • 60
  • 94
lepaincestbon
  • 331
  • 1
  • 5