typescript-expert
TypeScript and JavaScript expert including type systems, patterns, and tooling
от oimiragieo★ 48 звёзд на GitHub
Установить typescript-expert в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Об этом скилле
Typescript Expert
javascript code style and structure
When reviewing or writing code, apply these guidelines:
- Code Style and Structure
- Naming Conventions
- JavaScript Usage
javascript documentation with jsdoc
When reviewing or writing code, apply these guidelines:
- JSDoc Comments: Use JSDoc comments for JavaScript and modern ES6 syntax.
javascript typescript code style
When reviewing or writing code, apply these guidelines:
- Write concise, technical JavaScript/TypeScript code with accurate examples
- Use modern JavaScript features and best practices
- Prefer functional programming patterns; minimize use of classes
- Use descriptive variable names (e.g., isExtensionEnabled, hasPermission)
javascript typescript coding standards
When reviewing or writing code, apply these guidelines:
- Always use WordPress coding standards when writing JavaScript and TypeScript.
- Prefer writing TypeScript over JavaScript.
javascript typescript coding style
When reviewing or writing code, apply these guidelines:
- Use "function" keyword for pure functions. Omit semicolons.
- Use TypeScript for all code. Prefer interfaces over types. Avoid enums, use maps.
- File structure: Exported component, subcomponents, helpers, static content, types.
- Avoid unnecessary curly braces in conditional statements.
- For single-line statements in conditionals, omit curly braces.
- Use concise, one-line syntax for simple conditional statements (e.g., if (condition) doSomething()).
typescript code generation rules
When reviewing or writing code, apply these guidelines:
- Always use TypeScript for type safety. Provide appropriate type definitions and interfaces.
- Implement components as functional components, using hooks when state management is required.
- Provide clear, concise comments explaining complex logic or design decisions.
- Suggest appropriate file structure and naming conventions aligned with Next.js 14 best practices.
- Use the
'use client'directive only w
TypeScript 5.5–5.8 features (2025–2026)
Apply these modern features when writing or reviewing TypeScript code:
Inferred Type Predicates (TS 5.5)
TypeScript now infers type predicates from function bodies. No need to manually annotate x is T for simple filters.
// Before 5.5 — manual predicate required
const strings = values.filter((v): v is string => v !== null && typeof v === 'string');
// TS 5.5+ — predicate is inferred automatically
const strings = values.filter(v => v !== null && typeof v === 'string'); // string[]
Prefer letting TypeScript infer predicates over writing them by hand unless the inference is ambiguous.
Isolated Declarations (TS 5.5)
Enable "isolatedDeclarations": true in tsconfig for libraries and shared packages. This enforces that every exported symbol has an explicit type annotation, enabling parallel .d.ts generation by third-party tools (esbuild, oxc) without running tsc.
// Required when isolatedDeclarations: true
export function add(a: number, b: number): number {
return a + b;
}
// Omitting the return type annotation is an error under isolatedDeclarations
Use isolatedDeclarations for any published package or monorepo shared library. It also improves incremental build performance.
Never-Initialized Variable Checks (TS 5.7)
TS 5.7 catches variables that are declared but never assigned in any code path, even when accessed via inner functions.
// TS 5.7 reports error: 'result' has no initializer and is never assigned
function compute() {
let result: number;
printResult();
function printResult() {
console.log(result);
} // error
}
Enable this by keeping strict: true. No extra flag needed.
--erasableSyntaxOnly (TS 5.8)
Add "erasableSyntaxOnly": true to tsconfig for Node.js projects that use native TypeScript stripping (Node 22.6+ with --experimental-strip-types, or Node 23+). This flag turns enums, namespaces, and constructor parameter properties into compile errors.
// All three are errors under erasableSyntaxOnly: true
enum Status {
Active,
Inactive,
} // error — use const object instead
namespace Utils {
export const x = 1;
} // error — use a module instead
class Foo {
constructor(private x: string) {}
} // error — assign manually
Preferred replacements:
// Enum → const object + typeof
const Status = { Active: 'active
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
- 01
Read - 02
Write - 03
Edit - 04
Bash - 05
Grep - 06
Glob
Вложенные файлы
- commands/typescript-expert.md
- hooks/post-execute.cjs
- hooks/pre-execute.cjs
- references/research-requirements.md
- rules/typescript-expert.md
- schemas/input.schema.json
- schemas/output.schema.json
- scripts/main.cjs
- templates/implementation-template.md
FAQ
Что делает скилл typescript-expert?
TypeScript and JavaScript expert including type systems, patterns, and tooling
Как установить скилл typescript-expert?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл typescript-expert запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
theme-factory
AnthropicToolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
access
AnthropicManage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
configure
AnthropicSet up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
access
AnthropicManage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…