ts-standards

Enforce strict TypeScript conventions for type safety and code style.

Updated Aug 23, 2026
One-click install
npx skills add https://github.com/dungle-scrubs/agent-config --skill ts-standards
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ts-standards
Source: https://github.com/dungle-scrubs/agent-config/tree/main/stow/shared/skills/ts-standards
Command: npx skills add https://github.com/dungle-scrubs/agent-config --skill ts-standards

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill enforces strict TypeScript conventions to reduce runtime errors and improve maintainability.

Core Features & Use Cases

  • Enforces strict mode, readonly defaults, and discriminated unions to prevent subtle bugs.
  • Guides on interfaces, type aliases, generics, and error handling to improve readability and reliability across codebases.
  • Use Case: When adding a new module, apply the ts-standards guidelines to ensure consistent styles, naming, and type safety.

Quick Start

  • Audit all TypeScript files for strict options, avoid usage of any, and ensure explicit return types where appropriate.
  • Replace any usage with unknown or precise types and add runtime guards as needed.
  • Adopt readonly by default, consistent naming, and explicit discriminated unions across the codebase.

Frequently Asked Questions about ts-standards

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

FAQPage Schema
How do I enforce strict TypeScript conventions to reduce runtime errors in my project?

Enforce strict TypeScript conventions by enabling strict mode, adopting readonly defaults, and using discriminated unions to prevent subtle bugs and improve code maintainability across your project.

What is the best way to replace any types with safer alternatives in TypeScript?

Replace any types with unknown or precise types and add runtime guards as needed. This ensures explicit type safety and reliable error handling throughout your TypeScript codebase.

How do I apply consistent TypeScript coding standards when adding a new module?

Apply TypeScript coding standards to a new module by ensuring consistent styles, explicit naming, and strict type safety using interfaces, type aliases, and explicit discriminated unions.

Do I need explicit return types and readonly defaults for reliable TypeScript interfaces?

Yes, adopting readonly by default and adding explicit return types for TypeScript interfaces and type aliases improves readability and reliability while preventing accidental data mutation.

How do generics and type aliases improve readability and reliability in TypeScript?

Generics and type aliases improve TypeScript readability and reliability by allowing you to create reusable, precise type definitions and enforce consistent error handling patterns across codebases.

Can I use these TypeScript coding standards across different projects and teams?

Yes, these TypeScript coding standards specify frontmatter requirements, recommended patterns, and practical examples designed to guide developers and ensure consistent type safety across multiple projects and teams.