deno doc command generates and displays documentation from TypeScript/JavaScript source code.
Usage
Basic Examples
Output Formats
Output documentation as JSON
Generate HTML documentation
HTML Options
Output directory for HTML documentation
Project name for HTML documentation
Filtering Options
Filter documentation to specific symbol
Include private symbols in output
Linting
Check for documentation issues
Writing Documentation
JSDoc Comments
Deno uses JSDoc comments for documentation:JSDoc Tags
Supported JSDoc tags:@param- Document function parameters@returns- Document return values@example- Provide usage examples@deprecated- Mark as deprecated@see- Reference related documentation@throws- Document thrown exceptions@typeParam- Document type parameters@category- Categorize symbols in HTML output
Examples in Documentation
Examples
View Built-in APIs
Generate Module Documentation
Document Multiple Files
Check Documentation Quality
Integration with CI
Generate Documentation Site
HTML Documentation Features
When using--html, Deno generates a full documentation website with:
- Search functionality - Full-text search across all symbols
- Type information - Detailed type signatures and relationships
- Cross-references - Clickable links between related symbols
- Code examples - Syntax-highlighted examples from JSDoc
- Category organization - Group symbols using
@categorytag - Dark mode - Automatic dark/light theme support
Configuration
HTML generation can be customized indeno.json: