new-hook

Create a React Query hook with loading/error states and TypeScript types for data fetching

⭐0stars🔀0forks📁View on GitHub🕐Updated Jan 8, 2026⬇️1downloads

When & Why to Use This Skill

This Claude skill automates the creation of production-ready React Query hooks, integrating essential loading and error states with comprehensive TypeScript type definitions. It streamlines frontend development by generating type-safe boilerplate for efficient data fetching and state management.

Use Cases

  • Rapidly scaffolding custom hooks for new API endpoints to reduce manual boilerplate coding in React projects.
  • Ensuring consistent error handling and loading state patterns across a large-scale frontend codebase.
  • Implementing type-safe data fetching layers to improve developer productivity and reduce runtime errors in TypeScript applications.
namenew-hook
descriptionCreate a React Query hook with loading/error states and TypeScript types for data fetching

new-hook

Overview

Create a React Query hook with loading/error states and TypeScript types for data fetching

This skill was converted from a bash script to follow Anthropic's Agent Skills best practices.

Usage

new-hook <command> [options]

Commands

TODO: Extract and document commands from the script

Run new-hook --help to see available commands.

When to Use

TODO: Add specific use cases

Scripts

  • scripts/main.sh - Main functionality (converted from original new-hook)

Claude can execute this script directly without loading it into context.

Additional Resources

For detailed information, see:

Progressive Disclosure

Consider adding these reference files:

  • reference/api-reference.md - Detailed command documentation
  • reference/troubleshooting.md - Common issues and solutions