TypeScript Style Guide
An agent skill with TypeScript conventions: types, discriminated unions, functions, naming, source layout, React and tests, loaded per topic
Low risk
We rate an entry low when it mostly gives the agent instructions and reference material.
Why this level
- The skill is only conventions and reference text; it runs no code
Install
In your terminal, with SkillFoxx CLI
npx skillfoxx add skills/typescript-style-guideDetects the agents on your machine, checks the risk and pins the version.
Other ways to install
Run in a terminal in the project folder
npx skills add mkosir/typescript-style-guide --skill typescript-style-guide -a claude-code -yThe skills tool installs the current version from the repository. Add the -g flag to use the skill in every project.
Without third-party tools, from commit 170074a
tmp=$(mktemp -d)
git clone --filter=blob:none --no-checkout https://github.com/mkosir/typescript-style-guide.git "$tmp"
git -C "$tmp" sparse-checkout set --no-cone /skills/typescript-style-guide/
git -C "$tmp" checkout 170074a0df9b07f4a4a78e3596ec1edf06a14da7
mkdir -p .claude/skills
cp -R "$tmp/skills/typescript-style-guide" .claude/skills/typescript-style-guideCommands for macOS and Linux, on Windows run them in Git Bash.
Run in a terminal in the project folder
npx skills add mkosir/typescript-style-guide --skill typescript-style-guide -a cursor -yThe skills tool installs the current version from the repository. Add the -g flag to use the skill in every project.
Without third-party tools, from commit 170074a
tmp=$(mktemp -d)
git clone --filter=blob:none --no-checkout https://github.com/mkosir/typescript-style-guide.git "$tmp"
git -C "$tmp" sparse-checkout set --no-cone /skills/typescript-style-guide/
git -C "$tmp" checkout 170074a0df9b07f4a4a78e3596ec1edf06a14da7
mkdir -p .agents/skills
cp -R "$tmp/skills/typescript-style-guide" .agents/skills/typescript-style-guideCommands for macOS and Linux, on Windows run them in Git Bash.
Run in a terminal in the project folder
npx skills add mkosir/typescript-style-guide --skill typescript-style-guide -a github-copilot -yThe skills tool installs the current version from the repository. Add the -g flag to use the skill in every project.
Without third-party tools, from commit 170074a
tmp=$(mktemp -d)
git clone --filter=blob:none --no-checkout https://github.com/mkosir/typescript-style-guide.git "$tmp"
git -C "$tmp" sparse-checkout set --no-cone /skills/typescript-style-guide/
git -C "$tmp" checkout 170074a0df9b07f4a4a78e3596ec1edf06a14da7
mkdir -p .github/skills
cp -R "$tmp/skills/typescript-style-guide" .github/skills/typescript-style-guideCommands for macOS and Linux, on Windows run them in Git Bash.
Run in a terminal in the project folder
npx skills add mkosir/typescript-style-guide --skill typescript-style-guide -a codex -yThe skills tool installs the current version from the repository. Add the -g flag to use the skill in every project.
Without third-party tools, from commit 170074a
tmp=$(mktemp -d)
git clone --filter=blob:none --no-checkout https://github.com/mkosir/typescript-style-guide.git "$tmp"
git -C "$tmp" sparse-checkout set --no-cone /skills/typescript-style-guide/
git -C "$tmp" checkout 170074a0df9b07f4a4a78e3596ec1edf06a14da7
mkdir -p .agents/skills
cp -R "$tmp/skills/typescript-style-guide" .agents/skills/typescript-style-guideCommands for macOS and Linux, on Windows run them in Git Bash.
Run in a terminal in the project folder
npx skills add mkosir/typescript-style-guide --skill typescript-style-guide -a gemini-cli -yThe skills tool installs the current version from the repository. Add the -g flag to use the skill in every project.
Without third-party tools, from commit 170074a
tmp=$(mktemp -d)
git clone --filter=blob:none --no-checkout https://github.com/mkosir/typescript-style-guide.git "$tmp"
git -C "$tmp" sparse-checkout set --no-cone /skills/typescript-style-guide/
git -C "$tmp" checkout 170074a0df9b07f4a4a78e3596ec1edf06a14da7
mkdir -p .agents/skills
cp -R "$tmp/skills/typescript-style-guide" .agents/skills/typescript-style-guideCommands for macOS and Linux, on Windows run them in Git Bash.
Run in a terminal in the project folder
tmp=$(mktemp -d)
git clone --filter=blob:none --no-checkout https://github.com/mkosir/typescript-style-guide.git "$tmp"
git -C "$tmp" sparse-checkout set --no-cone /skills/typescript-style-guide/
git -C "$tmp" checkout 170074a0df9b07f4a4a78e3596ec1edf06a14da7
mkdir -p .devin/skills
cp -R "$tmp/skills/typescript-style-guide" .devin/skills/typescript-style-guideCommands for macOS and Linux, on Windows run them in Git Bash.
Formerly Windsurf.
Run in a terminal in the project folder
npx skills add mkosir/typescript-style-guide --skill typescript-style-guide -a cline -yThe skills tool installs the current version from the repository. Add the -g flag to use the skill in every project.
Without third-party tools, from commit 170074a
tmp=$(mktemp -d)
git clone --filter=blob:none --no-checkout https://github.com/mkosir/typescript-style-guide.git "$tmp"
git -C "$tmp" sparse-checkout set --no-cone /skills/typescript-style-guide/
git -C "$tmp" checkout 170074a0df9b07f4a4a78e3596ec1edf06a14da7
mkdir -p .cline/skills
cp -R "$tmp/skills/typescript-style-guide" .cline/skills/typescript-style-guideCommands for macOS and Linux, on Windows run them in Git Bash.
Run in a terminal in the project folder
npx skills add mkosir/typescript-style-guide --skill typescript-style-guide -a roo -yThe skills tool installs the current version from the repository. Add the -g flag to use the skill in every project.
Without third-party tools, from commit 170074a
tmp=$(mktemp -d)
git clone --filter=blob:none --no-checkout https://github.com/mkosir/typescript-style-guide.git "$tmp"
git -C "$tmp" sparse-checkout set --no-cone /skills/typescript-style-guide/
git -C "$tmp" checkout 170074a0df9b07f4a4a78e3596ec1edf06a14da7
mkdir -p .roo/skills
cp -R "$tmp/skills/typescript-style-guide" .roo/skills/typescript-style-guideCommands for macOS and Linux, on Windows run them in Git Bash.
A fork of Roo Code, same .roo folders.
Run in a terminal in the project folder
npx skills add mkosir/typescript-style-guide --skill typescript-style-guide -a opencode -yThe skills tool installs the current version from the repository. Add the -g flag to use the skill in every project.
Without third-party tools, from commit 170074a
tmp=$(mktemp -d)
git clone --filter=blob:none --no-checkout https://github.com/mkosir/typescript-style-guide.git "$tmp"
git -C "$tmp" sparse-checkout set --no-cone /skills/typescript-style-guide/
git -C "$tmp" checkout 170074a0df9b07f4a4a78e3596ec1edf06a14da7
mkdir -p .agents/skills
cp -R "$tmp/skills/typescript-style-guide" .agents/skills/typescript-style-guideCommands for macOS and Linux, on Windows run them in Git Bash.
Run in a terminal in the project folder
tmp=$(mktemp -d)
git clone --filter=blob:none --no-checkout https://github.com/mkosir/typescript-style-guide.git "$tmp"
git -C "$tmp" sparse-checkout set --no-cone /skills/typescript-style-guide/
git -C "$tmp" checkout 170074a0df9b07f4a4a78e3596ec1edf06a14da7
mkdir -p .agents/skills
cp -R "$tmp/skills/typescript-style-guide" .agents/skills/typescript-style-guideCommands for macOS and Linux, on Windows run them in Git Bash.
Run in a terminal in the project folder
tmp=$(mktemp -d)
git clone --filter=blob:none --no-checkout https://github.com/mkosir/typescript-style-guide.git "$tmp"
git -C "$tmp" sparse-checkout set --no-cone /skills/typescript-style-guide/
git -C "$tmp" checkout 170074a0df9b07f4a4a78e3596ec1edf06a14da7
mkdir -p .agents/skills
cp -R "$tmp/skills/typescript-style-guide" .agents/skills/typescript-style-guideCommands for macOS and Linux, on Windows run them in Git Bash.
Install the skill: npx skills add mkosir/typescript-style-guide and pick one from the list. For a specific topic add the flag, for example npx skills add mkosir/typescript-style-guide --skill typescript-types.
Other ways from the author
npx skills add mkosir/typescript-style-guideThe skill choice is interactive. For a specific topic add a flag, for example --skill typescript-types or --skill typescript-react.
This is third-party code. Review the repository files before installing.
What it does
The skill brings an opinionated TypeScript guide into a format for a coding agent so it applies a consistent style while writing and reviewing code. The complete skill routes by topic and reads only the reference the task needs, so it does not take extra context. Focused single-topic skills are available too: types, discriminated unions, functions, variables, naming, source organization, React and tests. It does not duplicate rules that TypeScript, linters and formatters already enforce, and it puts the repository's own conventions above its recommendations. It installs through npx skills add with a choice of which skill to add.
Who it is for. For TypeScript and React developers who want a consistent code style without style debates in review.
Good fit when
- You want the agent to apply a consistent TypeScript style while writing and reviewing code
- You need guidance on a single topic: types, functions, naming, React or tests
- You want to remove code-style debates from review
Not a fit when
- You only need a linter or formatter; the skill deliberately does not duplicate their rules
- The project is not written in TypeScript
Example request
Review this module against our TypeScript guideLimitations
The guide is opinionated, and the repository's own conventions take precedence. The skill applies only to TypeScript tasks, not to layout or styling. Installation runs through npx, so Node is required.
How to disable. Remove the installed skill folder from your agent's skills directory.
Security check
- The skill is only conventions and reference text; it runs no code
README in short
The README presents the project as a TypeScript style guide and, at the same time, a set of skills for a coding agent. Skills install via npx skills add with an interactive choice or a flag for a specific topic. The complete skill loads only the sections relevant to the task, while focused skills provide individual topics independently. The rationale section argues that a shared approach to code speeds up development and removes style debates from review. The full guide text is on the project site, MIT licensed.
SKILL.md
--- name: typescript-style-guide description: Apply, review, and explain the opinionated conventions in the TypeScript Style Guide. Use automatically only when TypeScript conventions are part of the requested task, including type modelling, discriminated unions, function APIs, variables and state, naming, source organization, React props, component APIs, state management, data flow, or tests. Do not use for styling or layout alone. --- # TypeScript Style Guide Apply only the conventions relevant to the current task. Keep TypeScript, linters, and formatters responsible for rules they can enforce automatically. ## Workflow 1. Inspect the consuming repository's conventions and configuration. 2. Let explicit repository conventions take precedence over this opinionated guide. 3. Identify which guide topic applies. 4. Read only the reference for the task's primary guide topic. Read multiple references only when the task substantively spans multiple topics. 5. Apply, review, or explain the conventions in the context of the current task. 6. State important tradeoffs when a convention depends on context or judgment.
FAQ
Does it replace ESLint and Prettier?
No. It deliberately avoids duplicating what a linter and formatter enforce and covers conventions that cannot be expressed as a tool rule.
Can I install just one topic?
Yes, each topic has its own skill added with the --skill flag, for example typescript-react or typescript-tests.
Related
A skills library that gives coding agents a development process: brainstorming, planning, TDD, subagents and code review
Skills for real engineers by Matt Pocock
Skills For Real Engineers
Small composable skills for engineering with agents: plan grilling, TDD, bug diagnosis, code review and architecture
GitHub toolkit for spec-driven development: the specify CLI adds agent commands and skills to a project, from principles to implementation
Reference MCP servers
Model Context Protocol servers
Official reference MCP servers: Filesystem, Fetch, Git, Memory, Sequential Thinking, Time and Everything