typescript-masteryTypeScript advanced patterns — branded types, discriminated unions, template literals, generics, type guards, tsconfig optimization, and migration strategies
Install via ClawdBot CLI:
clawdbot install msruruguay/typescript-masteryGrade Fair — based on market validation, documentation quality, package completeness, maintenance status, and authenticity signals.
Calls external URL not in known-safe list
https://www.typescriptlang.org/docs/Audited Apr 17, 2026 · audit v1.0
Generated Mar 21, 2026
Implement branded types for currency values (USD, EUR) and account IDs to prevent mixing different financial entities, ensuring type safety in transactions and reporting. Use discriminated unions for transaction states (pending, completed, failed) with exhaustive checking to handle all possible outcomes securely.
Leverage template literal types to define type-safe API endpoints (e.g., GET /products, POST /cart) and event names, reducing runtime errors. Apply custom type guards and Zod validation to sanitize user input and API responses, enhancing data integrity and security.
Use discriminated unions for patient statuses (admitted, discharged, in-treatment) with exhaustive checks to ensure all medical workflows are handled. Implement branded types for patient IDs and medical record numbers to avoid misidentification, critical for compliance and safety.
Apply const assertions for user roles and permissions (admin, editor, viewer) to enable better tree-shaking and performance. Use generics with constraints to build reusable components for chat messages or document edits, ensuring type safety across different data structures.
Follow the incremental migration strategy to convert a large JavaScript codebase to TypeScript, starting with non-critical modules and using tsconfig optimizations for faster compilation. Replace any with unknown and type guards to gradually improve type safety without disrupting existing functionality.
Offer a subscription-based service for web development teams, providing advanced TypeScript patterns and tsconfig optimizations to reduce build times and improve code quality. Revenue comes from monthly or annual licenses, with tiers based on team size and support levels.
Provide expert consulting to enterprises migrating from JavaScript to TypeScript, using the skill's patterns for branded types and performance tuning. Revenue is generated through project-based contracts or hourly rates, focusing on reducing technical debt and enhancing developer productivity.
Conduct workshops and online courses teaching TypeScript mastery, covering topics like discriminated unions and runtime validation with Zod. Revenue streams include course fees, corporate training packages, and certification programs for developers seeking to upskill.
💬 Integration Tip
Integrate this skill by first applying tsconfig.json performance settings like incremental and skipLibCheck for faster builds, then gradually introducing patterns such as branded types and Zod validation in critical modules to enhance type safety without overwhelming the team.
Scored Apr 19, 2026
AI creative writing and storytelling powered by CellCog. Novels, short stories, screenplays, fan fiction, poetry. World building, character development, narrative design across fantasy, sci-fi, mystery, romance, horror, and literary fiction.
AI YouTube content creation powered by CellCog. YouTube videos, Shorts, thumbnails, video scripts, tutorials, vlogs, educational videos, product reviews, video essays. From script to finished video with voiceover and music.
You are a professional writer, skilled in writing all kinds of materials. Markdown is the exclusive format for your writing outputs.rrent user query.The othe...
AI长篇网文创作技能包。用于解决长篇网络小说创作中的核心痛点:上下文丢失、文风不一致、设定冲突、节奏失控、多线混乱、质量不稳、读者反馈无法内化。触发场景包括:开始新书、规划大纲、撰写章节、管理伏笔、检测冲突、读者反馈分析、批量创作质量控制。
Deprecated redirect skill that routes legacy 'content creator' requests to the correct specialist. Use when a user invokes 'content creator', asks to write a...
Refine academic writing for computer science research papers targeting top-tier venues (NeurIPS, ICLR, ICML, AAAI, IJCAI, ACL, EMNLP, NAACL, CVPR, WWW, KDD, SIGIR, CIKM, and similar). Use this skill whenever a user asks to improve, polish, refine, edit, or proofread academic or research writing — including paper drafts, abstracts, introductions, related work sections, methodology descriptions, experiment write-ups, or conclusion sections. Also trigger when users paste LaTeX content and ask for writing help, mention "camera-ready", "rebuttal", "paper revision", or reference any academic venue or conference. This skill handles both full paper refinement and section-by-section editing.