scribble
scribble copied to clipboard
Package catalog links?
In the block that defmodule
outputs:
... it would be nice if the
package: mock
text was also a hyperlink to the mock package catalog entry (https://pkgd.racket-lang.org/pkgn/package/mock). I'm not sure how to implement this when different packages on the same system are installed from catalogs other than pkgd.racket-lang.org
, or what to do for packages that aren't installed from a catalog at all.
What if defmodule
took an optional "external link" argument?
Something like: @defmodule[mock #:url "pkgd.racket-lang...."]
I would want to avoid an API that forced a package's documentation to assume which catalog the package would be published in, but that could work as a kludge.
How about #:catalog-package-url
, which is a format
-style string that defaults to https://pkgs.racket-lang.org/package/~a
?
I discussed this with @mflatt and committed a WIP version while he lets me know the better way to improve it. The important take-away is that packages should not be referred to haphazardly because it is not up to the author where to get the package from, so the documentation should detect where it got the package from. (That doesn't say anything about the case where you want to refer to a package that isn't installed.)