imcomplete-library-class

Detect missing methods in read-only TypeScript library classes.

Updated Mar 26, 2026
One-click install
npx skills add https://github.com/johnnystefan/test-saas-business --skill imcomplete-library-class
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: imcomplete-library-class
Source: https://github.com/johnnystefan/test-saas-business/tree/main/skills/imcomplete-library-class
Command: npx skills add https://github.com/johnnystefan/test-saas-business --skill imcomplete-library-class

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Detects when a library class is missing methods the project needs but is read-only, preventing direct extension and forcing duplicated helper code across clients. It keeps teams from hacking around limitations by copying behavior into every caller and highlights when a strategic extension is warranted.

Core Features & Use Cases

  • Missing Method Detection: Spot repetitive client utilities that reveal the library needs additional helpers yet cannot be changed.
  • Foreign Method Guidance: Show how to add small helpers within client classes that accept the vendor object for lightweight fixes.
  • Local Extension Guidance: Recommend wrapping or subclassing the third-party class for more extensive functionality so the codebase talks to a richer API.
  • Use Case: When an external date class only exposes getters, decide between a foreign DateUtil helper and an ExtendedDate subclass so team code can call addDays, format, or isWeekend.

Quick Start

Determine whether to implement a foreign method or a local extension for the read-only library class lacking new behaviors.

Frequently Asked Questions about imcomplete-library-class

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

FAQPage Schema
How do I extend a third-party TypeScript class that is missing methods but cannot be modified directly?

A foreign method adds small helpers within client classes that accept the vendor object for lightweight fixes. It is ideal when you only need minor utilities and want to avoid creating a full wrapper or subclass around the library object.

When should I use a local extension wrapper versus a foreign method for a read-only library?

Use a local extension wrapper or subclass when adding extensive functionality so your codebase talks to a richer API. Use a foreign method for small, lightweight fixes that accept the vendor object without creating a new class layer.

What is the best way to add custom helper functions to a read-only library class in TypeScript?

Detect repetitive client utilities that reveal the library needs additional helpers yet cannot be changed. This pattern highlights when a strategic extension is warranted, preventing teams from hacking around limitations by copying behavior into every caller.

Why does adding methods directly to a vendor class fail in TypeScript?

Adding methods directly fails because third-party library classes are often read-only or locked, preventing direct extension. Modifying vendor source risks breaking updates and forces duplicated helper code across clients, requiring alternative extension strategies.