racket Documenting a binding provided by a package


#lang scribble/manual

@; Make sure that code highlighting recognises identifiers from my-package:

@; Indicate which module is exporting the identifiers documented here.

@defproc[(my-procedure [arg1 number?] [arg2 string?]) symbol?]{
  The @racket[my-procedure] function repeats the @racket[arg2] string
  @racket[arg1] times, and transforms the result into a symbol.

  @history[#:added "1.0"
           #:changed "1.1" @elem{Improved performance,
                                 from @tt{O(n²)} to @tt{O(n)}}]

As a rule of thumb, a module (something that could appear on the right of a (require foo/bar), i.e. foo/bar) should be documented by a single .scribble file. A .scribble file can document several modules, as long as each one is documented in a separate @section.