Skip to content
Back to skills

Typescript Boundaries

ASecurity

Strengthen TypeScript input and module boundaries with runtime validation, explicit domain states, and verified build/runtime resolution.

  • 3 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added October 13, 2026
developmenttypescriptrustnodegitapidocumentation

Works with

  • api

Security analysis

A100/100

Scanned October 13, 2026

npx -y skills add sujith011/agentic-pro-skills --skill typescript-boundaries --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Typescript Boundaries?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Typescript Boundaries
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/sujith011-typescript-boundaries/badge)](https://www.skillsdirectory.com/skills/sujith011-typescript-boundaries)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: typescript-boundaries
description: "Strengthen TypeScript input and module boundaries with runtime validation, explicit domain states, and verified build/runtime resolution."
---

# TypeScript Boundaries

## Process
1. Identify untrusted values entering through HTTP, storage, environment, messaging, and third-party APIs. Static interfaces disappear at runtime.
2. Accept unknown at external boundaries, validate using the project's schema/tool conventions, and narrow into domain types. Reject or deliberately handle extra fields.
3. Represent mutually exclusive states with discriminated unions and test exhaustive handling. Use units or branded identifiers where mixing values would cause a concrete defect.
4. Keep public types small and stable. Avoid broad any, unchecked assertions, or disabling type checks to silence a real mismatch.
5. Inspect the actual compiler configuration, package exports, module mode, and build runner. A TypeScript path alias does not automatically configure Node or the bundler.
6. Run type checking and the relevant emitted-code/runtime path. Verify malformed data and real package imports; compilation alone cannot establish either.

## Example
An API returns an amount as an arbitrary string. Validate finite numeric syntax and the domain's range/units before calculation instead of casting the JSON to an Invoice interface.

## Stop conditions
Do not introduce elaborate generic types for a simple local invariant. Resolve version-specific behavior from the installed compiler and official documentation.

## Evidence
- Boundary schema and invalid-input cases.
- Type-check result and relevant runtime check.
- Public compatibility and any remaining assertions.

## Reference
Workflow independently written after reviewing [typescript-expert](https://github.com/sickn33/agentic-awesome-skills/blob/cb30121a2dfd007531bd2fbefb56f68de927da6a/skills/typescript-expert/SKILL.md).

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.