auto-doc-gen

Your awesome auto-doc-gen extension for VS Code...
Generate rich documentation for your TypeScript code in Markdown and HTML — right from VS Code.
Features
-
- Parses TypeScript files or folders
-
- Supports:->
- Function declarations
- Arrow functions
- JSDoc comments (
@param
, @returns
)
- Interfaces
- Enums
- Classes
- Constructor
- Properties
- Methods
- Type Aliases
-
- Outputs clean and structured:
DOCS.md
docs.html
-
- VS Code integrated — works via Command Palette
Installation
- Clone this repository
git clone https://github.com/111saurabh/auto-doc-gen
cd auto-doc-gen
- Open it in VS Code
- Press
F5
to launch the extension in a new Extension Development Host window
Usage
- Open the Command Palette (
Ctrl+Shift+P
)
- Type
Generate Docs
and select auto-doc-gen: Generate Docs
- Select a
.ts
file or a folder containing TypeScript files
- Select option which output file you want to see
- Done! You’ll see
DOCS.md
or docs.html
as per choice created in your workspace
In case you don't have , Use this well-commented sample TypeScript file to test the extension: https://github.com/111saurabh/test-for-auto-doc-gen.git
Example
Input:
/**
* Adds two numbers
* @param a - First number
* @param b - Second number
* @returns Sum of a and b
*/
const add = (a: number, b: number): number => {
return a + b;
}
Output (Markdown):
## Function: `add`
**Description:** Adds two numbers
**Parameters:**
- a - First number
- b - Second number
**Returns:** Sum of a and b
```ts
const add = (a: number, b: number): number => {
return a + b;
}
---
## Roadmap
- [x] Support function & arrow function docs
- [x] Support for classes & interfaces
- [x] Add 'Download as PDF' feature
- [x] Publish on VS Code Marketplace
- [ ] Add configuration options (output path, style)
- [ ] Advanced Features...
---
## Contributing
Pull requests and suggestions are welcome. Let's build better docs together!
---
## License
This project is licensed under the MIT License - see the [LICENSE](https://github.com/111saurabh/auto-doc-gen/blob/HEAD/LICENSE) file for details.
MIT © 2025 [Saurabh Doke](https://github.com/111saurabh)
## Version History
- **0.0.1** - Initial release with support for function & arrow function documentation generation.
- **1.1.0** - Added support for user interface, enum, class etc. File selection improved.
- **1.1.3** - Added dark themed output with better visual representation
- **1.2.0** - Added 'Download as PDF' feature in HTML output