jsdoc

Automate creation and updating of JSDoc comments for JavaScript and TypeScript functions.

138|6|Updated Jan 25, 2025
One-click install
npx skills add https://github.com/yamcodes/arkenv --skill jsdoc-yamcodes
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: jsdoc
Source: https://github.com/yamcodes/arkenv/tree/main/skills/jsdoc
Command: npx skills add https://github.com/yamcodes/arkenv --skill jsdoc-yamcodes

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill helps you automatically write or fix JSDoc comments for JavaScript and TypeScript functions, ensuring consistent documentation across your codebase.

Core Features & Use Cases

  • Generate JSDoc blocks for new or existing functions without type annotations.
  • Update existing JSDoc when the function's behavior changes, avoiding unnecessary rewrites.
  • Ensure comprehensive documentation for parameters, returns, and exceptions across modules.

Quick Start

Document functions with clear, imperative JSDoc blocks by running the tool on your TypeScript or JavaScript files and reviewing the generated comments.

Frequently Asked Questions about jsdoc

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate JSDoc comments for JavaScript and TypeScript functions?

To generate JSDoc comments, you can apply an automated tool to your TypeScript and JavaScript files to create standard documentation blocks for function inputs, outputs, and exceptions, ensuring consistency across your codebase.

Can I automatically update existing JSDoc comments when the code changes?

Yes, you can automatically update existing JSDoc comments when a function's behavior changes. The tool analyzes modifications and updates documentation only when necessary, avoiding unnecessary rewrites of unaffected code blocks.

How do I document only new or changed functions in a pull request?

You can document only changed or new functions in a pull request by applying the JSDoc generation process selectively. This targets recent modifications to add missing documentation without rewriting stable, existing code.

What is the best way to ensure consistent JSDoc standards across a codebase?

The best way to ensure consistent JSDoc standards is to automate the creation and updating of documentation blocks for all functions. This enforces uniform documentation of parameters, returns, and exceptions across entire files or modules.

Does this JSDoc generation approach work with both TypeScript and JavaScript?

Yes, this JSDoc generation approach works with both TypeScript and JavaScript files. It applies standard JSDoc rules to document functions comprehensively, regardless of whether your project uses static typing or plain JavaScript.