contentful/skill-kit

ts-patterns

TypeScript patterns and idioms reference.

ソースを見る

使い方

  1. インストールコマンドをコピーし、自分の環境へ導入する前にソースを確認します。
  2. 必要なツール、認証情報、対応環境を原文で確認します。
  3. 入力と成果物を指定し、出力を資料と照合します。
npx skills add https://github.com/contentful/skill-kit --skill ts-patterns

開始前の確認

  • 導入にはモデル契約、API枠、ファイルへのアクセス許可は含まれません。
  • スター数や導入数は活動の指標であり、独立した品質・安全性試験ではありません。
リポジトリの原文

見出し、例、コード、表、リンク、参照画像を含む原文を表示しています。

ts-patterns

This skill provides reference information on demand.

MCP mode (preferred)

If you have MCP tools for this skill (e.g., mcp__ts-patterns__topic), use them:

  • Call topics to list available reference topics.
  • Call topic with a topic name to retrieve its content.

Present the content to the user. Do not show raw tool calls.

CLI mode (fallback)

Resolve the absolute path to scripts/run from this SKILL.md file's directory. Use the absolute path in all commands — do not cd into the skill directory. In the examples below, <skill>/scripts/run is a placeholder for this absolute path.

  • <skill>/scripts/run topic generics — Generics cheat sheet — constraints, conditional types, mapped types, infer
  • <skill>/scripts/run topic discriminated-unions — Discriminated unions — type narrowing with literal discriminants
  • <skill>/scripts/run topic builder-pattern — Builder pattern — fluent APIs with type accumulation
  • <skill>/scripts/run topic error-handling — Error handling — Result types, custom errors, exhaustive matching

To list all available topics: <skill>/scripts/run

タスクに関連する項目

同じリポジトリから

関連する Skills

すべての Skills