typescript

typescript is a skill for Claude Code, Codex from genkit-ai/genkit. It costs 20 tokens per session (534 once invoked), scanned A, original, Apache-2.0.

A coding style guide for TypeScript, a programming language that adds type checking to JavaScript.

In plain words
What is it for?
It helps write, review, and maintain TypeScript functions, classes, interfaces, files, and error-handling code.
Why use it?
It reduces inconsistent code and common errors by defining rules for types, naming, file layout, errors, and asynchronous operations.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit It helps write, review, and maintain TypeScript functions, classes, interfaces, files, and error-handling code.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/genkit-ai/genkit/typescript
About the project

Genkit is an open-source framework for building AI-powered applications with JavaScript, Go, Python, and Dart. Developers use it to connect language models and other AI providers while implementing chatbots, automations, recommendations, multimodal features, structured outputs, tools, and agent workflows. The catalogue skills support development with Genkit.

genkit-ai/genkit · 6,523 stars · on GitHub · genkit.dev

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add genkit-ai/genkit --skill typescript
Clone the repo
git clone --depth 1 https://github.com/genkit-ai/genkit

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for typescript

README.md
[![agentmods](https://agentmods.dev/badge/skills/genkit-ai/genkit/typescript/github.svg)](https://agentmods.dev/skills/genkit-ai/genkit/typescript)
Your own site
<a href="https://agentmods.dev/skills/genkit-ai/genkit/typescript"><img src="https://agentmods.dev/badge/skills/genkit-ai/genkit/typescript/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for typescript

Your own site · 80×15
<a href="https://agentmods.dev/skills/genkit-ai/genkit/typescript"><img src="https://agentmods.dev/badge/skills/genkit-ai/genkit/typescript.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 20 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 534 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00020 $0.00534
Opus 5.5 $0.00008 $0.00214
Sonnet 5.5 $0.00004 $0.00107
Haiku 4.5 $0.00002 $0.00053

Measured 1mo ago against content hash fef4f53ee3dc, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

typescript scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

js/testapps/agents/skills/typescript/SKILL.md · 79 lines

How it starts

The opening of the file, as written. The whole thing — 79 lines — stays where its author put it; the contents beside it link to each section on GitHub.

TypeScript Coding Conventions

General Principles

  • Use TypeScript strict mode ("strict": true in tsconfig.json).
  • Prefer const over let; never use var.
  • Use explicit return types on exported functions.
  • Prefer interfaces over type aliases for object shapes.
  • Use unknown instead of any where possible.

Naming Conventions

  • Variables & functions: camelCase
  • Classes & interfaces: PascalCase
  • Constants: UPPER_SNAKE_CASE for true constants, camelCase for derived values
  • Files: kebab-case.ts
  • Type parameters: Single uppercase letter (T, K, V) or descriptive (TResult)

File Structure

src/
  index.ts          # Entry point, exports
  types.ts          # Shared type definitions
  utils/            # Utility functions
  services/         # Business logic
  middleware/       # Express/framework middleware

Error Handling

  • Use typed errors (extend Error class).
  • Always handle promise rejections.
  • Prefer try/catch with specific error types over generic catches.
class AppError extends Error {
  constructor(
    message: string,
    public readonly code: string,
    public readonly statusCode: number = 500
  ) {
    super(message);
    this.name = 'AppError';
  }
}

Async Patterns

  • Use async/await over raw promises.
  • Use Promise.all() for concurrent independent operations.
  • Avoid mixing callbacks and promises.

Imports

  • Use named imports: import { thing } from './module'
  • Group imports: external packages first, then internal modules.
  • Use .js extensions in import paths for ESM compatibility.

Code Style

  • Maximum line length: 100 characters.
  • Use template literals for string interpolation.
  • Prefer Array.map/filter/reduce over for loops for transformations.
  • Use optional chaining (?.) and nullish coalescing (??).
  • Destructure objects and arrays when accessing multiple properties.

Testing

  • Co-locate test files: thing.ts → thing.test.ts
  • Use descriptive test names: it('should return empty array when no items match')
  • Test edge cases: empty inputs, null values, error conditions.

Read the full file on GitHub · 79 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 79 lines · 20 tokens per session scan A fef4f53ee3dc

Subscribe to this mod's changes

typescript is a skill published in the GitHub repository genkit-ai/genkit (6,523 stars, last pushed today), licensed Apache-2.0. It adds 20 tokens to every session and 534 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

typescript-development

You MUST activate this skill when working on TypeScript or JavaScript projects.

sammcj/agentic-coding · 17 tokens

js-gof

Apply Gang of Four and related design patterns in JavaScript and TypeScript. Use when implementing creational, structural, or behavioral patterns, or when the user mentions factories, builder, prototype, flyweight, singleton, object pool, adapter, wrapper, decorator, proxy, bridge, composite, facade, chain of…

metarhia/metaskills · 107 tokens

error-handling

Apply error handling and recovery patterns in JavaScript/TypeScript or Node.js. Use when implementing error handling, retry logic, or when the user mentions domain errors, error recovery, error escalation.

metarhia/metaskills · 43 tokens

js-conventions

Apply Metarhia JavaScript style. Use when writing or editing .js, .mjs, .ts files (with certain corrections for typescript), formatting code, or when the user asks about code style or linting.

metarhia/metaskills · 50 tokens

pn-godot-dev

Guides Godot Engine 4.x development: GDScript, GDExtension (C++), multiplayer, VisualShader/shader code, export/platform config, autoloads, Resource serialization, InputMap, headless CI, AnimationPlayer/Tree, 2D/3D workflows, physics, PCG, and Blender pipeline. Use when developing Godot 4.x projects.

perniemann/pnCore · 86 tokens

pn-node-api

Guides Node/API design, DB access patterns, and env/secrets. Use when designing or implementing Node/API code; covers API design, error handling, config, and DB patterns.

perniemann/pnCore · 41 tokens