Typescript Clean Code

bmad-labs/skills/skills/typescript-clean-code

by bmad-labsf2e09b317c6fNo license16 starsListed Oct 8, 2026Updated Oct 8, 2026Repository updated 3 weeks ago

Clean Code for TypeScript — code smell catalogs (Martin's per-line heuristics, Fowler's change-shape smells, TypeScript-native type smells), a linter-first detection policy, and step-by-step review, refactoring, TDD, and estimation workflows. Use when the user: - Writes, reviews, or refactors TypeScript/JavaScript code, or asks whether code is clean, maintainable, or well-designed - Names a smell — Shotgun Surgery, Feature Envy, Data Clumps, Long Method, Divergent Change, Duplicated Code, Large Class, Long Parameter List, Primitive Obsession, Message Chains, Dead Code, Speculative Generality, god class, copy-paste, stringly typed, premature abstraction - Asks about TypeScript type hygiene — `any` leakage, `as` assertions, non-null `!`, discriminated unions, exhaustiveness, strict flags, branded types - Asks what to enforce with lint or tsconfig versus what needs judgment, or names knip, jscpd, dependency-cruiser, typescript-eslint, type-coverage - Runs TDD, fixes a bug with test coverage, or plans test strat

Add to a SourceWeft workspace

  1. Open the skill in your dashboard and add it to a workspace.
  2. Enable it for the chats that should use it.

This skill is instructions only: it ships no scripts to execute.

Add to SourceWeft

You will be asked to sign in first, then taken straight to this skill.

Ask your agent to install it

Paste this prompt into Claude Code, Codex, Cursor or another agent that can run commands — or into SourceWeft chat. The agent reads this skill's install guide, shows you its source, license and scripts, and installs it with the SourceWeft CLI once you agree.

Read https://sourceweft.com/skills/gh-bmad-labs-skills-typescript-clean-code/install.md and install the skill it describes. Before installing, show me its source, license and whether it ships scripts, and wait for my OK. Ask me before changing anything else on my machine.

Read the install guide the agent follows

Install it yourself from a terminal

For Claude Code, Codex, Cursor and other local agents. The SourceWeft CLI fetches the skill from its source repository at the commit scanned here, and verifies every file against the hashes recorded when the skill was scanned. If anything differs, nothing is written.

npx @sourceweft/cli skills install @bmad-labs/typescript-clean-code

Add --agent claude-code, codex, cursor or universal to choose which agent gets it (Claude Code by default).

Upstream installer — not verified by SourceWeft

The open-source skills installer fetches the same pinned commit, but does not check the files against the hashes SourceWeft recorded.

npx skills add https://github.com/bmad-labs/skills/tree/f2e09b317c6fc7cd1d926e424388adb52310dad7/skills/typescript-clean-code

Source and attribution

Source:bmad-labs/skillsinskills/typescript-clean-codeat commitf2e09b3

License: No license

Content belongs to its original authors. SourceWeft indexes it from a public repository.

Report or request removal