@eryxdoc/parse/doctags Module
Parses doc-comment tags from raw comment text.
Supported tags:
@yields Marks function as yieldable (no arguments)
@param [description] Parameter documentation (name must match a known param)
@param -- [desc] Parameter with explicit type override
@return [description] Return value documentation
@return -- [description] Return with explicit type
@error -- [description] Documents a possible error (type parsed if -- present)
@unreleased Marks as unreleased
@since Version when this was introduced
@deprecated Marks as deprecated
@deprecated [description] Deprecated with reason
@deprecated -- [desc] Deprecated at version with reason
@private Marks as private (excluded from public docs)
@ignore Totally excluded from generated documentation
@reexportonly Hide on source module; show when re-exported
@tag Adds a custom tag
API Reference
Types
type ParsedParam = { name: string, description: string, typeOverride: string? }
type ParsedError = { description: string, type: string? }
type ParsedDoc = {
body: string,
params: { ParsedParam },
returns: { ParsedReturn },
errors: { ParsedError },
yields: boolean,
unreleased: boolean,
since: string?,
deprecated: DeprecatedInfo?,
private: boolean,
ignore: boolean,
reexportOnly: boolean,
tags: { string }
}