yuvrajkarna2717/react-hook-granth

[Docs]: Add JSDoc documentation to all hooks

開放

#5 建立於 2025年12月6日

 (0 則留言) (0 個反應) (0 位負責人)JavaScript (1 個分叉)auto 404
documentationenhancementhelp wanted

倉庫指標

星標
 (3 顆星)
PR 合併指標
 (PR 指標待抓取)

描述

Description: Add comprehensive JSDoc comments to all existing hooks for better IntelliSense and developer experience.

Requirements:

  • Add JSDoc comments to all hook functions
  • Include parameter descriptions
  • Include return value descriptions
  • Add usage examples in comments

Example:

/**
 * A hook that manages counter state with increment, decrement, and reset functionality.
 * 
 * @param initialValue - The initial counter value (default: 0)
 * @returns An object containing the current count and control functions
 * 
 * @example
 * ```tsx
 * const { count, increment, decrement, reset } = useCounter(10);
 * ```
 */
export default function useCounter(initialValue: number = 0) {
  // implementation
}

貢獻者指南