원클릭으로
typescript
Write type-safe TypeScript with proper narrowing, inference patterns, and strict mode best practices.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Write type-safe TypeScript with proper narrowing, inference patterns, and strict mode best practices.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
Create a new repo-local OpenCode skill scaffold
This skill should be used when the user asks to "create a proposal", "design a report", "make a one-pager", "build a PDF", "create a newsletter", "design slides", "make event materials", "design a flyer", or needs help with print-ready HTML documents. Provides brand configuration, CSS patterns for print layout, and document design best practices.
Use common project commands via just
Understand project structure, directories, and checks configuration
Use swimlane for task tracking with proper workflow
Astro web framework patterns for content-driven sites. Covers content collections with Zod schemas and loaders, island architecture with selective hydration directives, view transitions with ClientRouter, server-side and hybrid rendering modes, server islands, Astro DB with astro:db, middleware with onRequest, and framework integrations (React, Svelte, Vue). Use when building content-driven websites, configuring island hydration strategies, setting up view transitions, choosing between static and server rendering, integrating UI framework components, defining content collection schemas, or adding middleware.
| name | TypeScript |
| slug | typescript |
| version | 1.0.2 |
| description | Write type-safe TypeScript with proper narrowing, inference patterns, and strict mode best practices. |
User needs TypeScript expertise — from basic typing to advanced generics. Agent handles type narrowing, inference, discriminated unions, and strict mode patterns.
| Topic | File |
|---|---|
| Generic patterns | generics.md |
| Utility types | utility-types.md |
| Declaration files | declarations.md |
| Migration from JS | migration.md |
anyunknown forces you to narrow before use — any silently breaks type safetyunknown, never anyunknown, not anyfilter(Boolean) doesn't narrow — use .filter((x): x is T => Boolean(x))Object.keys(obj) returns string[], not keyof typeof obj — intentional, objects can have extra keysArray.isArray() narrows to any[] — may need assertion for element typein operator narrows but only if property is in exactly one branch of unionlet x = "hello" is string — use const or as const for literal type{ status: "ok" } has status: string — use as const or type annotationfn<T>() can't infer, pass a value or annotatetype or kind field to each variant — enables exhaustive switchdefault: const _never: never = x — compile error if case missedsatisfies vs Type Annotationconst x: Type = val widens to Type — loses literal infoconst x = val satisfies Type keeps literal, checks compatibility — prefer for config objects?. returns undefined, not null — matters for APIs expecting null?? only catches null/undefined — || catches all falsy including 0 and ""! should be last resort — prefer narrowing or early returnimport type for type-only imports — stripped at runtime, avoids bundler issuesexport type { X } — prevents accidental runtime dependency.d.ts augmentation: use declare module with exact module path