Extension talk:Scribunto/Documentation specification
The template documentation system is pretty good--basically, there's a subpage of whatever Template you're accessing, called "Template:TplName/Doc", where the docs are stored. Well, we could easily have something similar. So either
- Use a subpage named "Module:ModuleName/Doc", EXACTLY like we would have for the Template that we're replacing. Auto-transclude that puppy into the main page, but (obviously) don't execute it when the Module is invoked. Or,
- Assume that every module has a method called doc, and call it to generate the docs. This has the benefit of being in the same page, and of being somewhat more automatic (you could easily change a default value, for example, without having to update the docs).