util-function

Generate TypeScript utility functions with tests and JSDoc examples.

11|Updated Apr 16, 2026
One-click install
npx skills add https://github.com/berkcangumusisik/claude-code-practices --skill util-function
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: util-function
Source: https://github.com/berkcangumusisik/claude-code-practices/tree/main/skills/util-function
Command: npx skills add https://github.com/berkcangumusisik/claude-code-practices --skill util-function

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps teams turn a natural-language description into a well-typed, tested utility function, reducing boilerplate and integration effort across a codebase.

Core Features & Use Cases

  • Automatically detect an existing similar utility and extend it, or scaffold a new one under src/utils with TypeScript generics and edge-case handling.
  • Write comprehensive unit tests for normal usage and edge cases, including null/undefined handling, and provide a JSDoc usage example.
  • Promote clean project structure by placing new utilities in a consistent location and enabling easy usage across modules.

Quick Start

Describe the desired utility in natural language and the tool will generate a typed function, tests, and a usage example placed in src/utils.

Frequently Asked Questions about util-function

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

FAQPage Schema
How do I generate a TypeScript utility function from a natural language description?

To generate a TypeScript utility function from a description, provide a natural language prompt and the tool scaffolds typed code with generics under src/utils. It also writes unit tests and a JSDoc usage example.

What is the best way to scaffold tested utility functions with edge-case handling?

The best way to scaffold tested utility functions with edge-case handling is using an automated generator. It creates typed code and writes unit tests for normal usage alongside null/undefined edge cases.

Can I extend an existing TypeScript utility instead of creating a new one?

Yes, you can extend an existing TypeScript utility. The tool searches your codebase for similar utilities to extend or replace before scaffolding new code, reducing duplicate boilerplate across modules.

Does the generated utility function include TypeScript generics and JSDoc?

Yes, the generated utility function includes TypeScript generics and JSDoc. The tool scaffolds typed code with generics and documents usage with a JSDoc example for easy module integration.

How do I write unit tests for null and undefined edge cases in utility functions?

To write unit tests for null and undefined edge cases, describe the desired utility in natural language. The generator automatically writes comprehensive tests covering normal usage and edge cases.