Agent skill
forge-lang-typescript
TypeScript development standards including type checking, jest/vitest, eslint, and prettier. Use when working with TypeScript files, tsconfig.json, or .ts/.tsx files.
Install this agent skill to your Project
npx add-skill https://github.com/martimramos/claude-forge/tree/main/skills/languages/typescript
SKILL.md
TypeScript Development
Type Checking
# Check types without emitting
npx tsc --noEmit
# Watch mode
npx tsc --noEmit --watch
Testing
# Run all tests
npm test
# Run with coverage
npm test -- --coverage
# Run in watch mode
npm test -- --watch
# Run specific test
npm test -- --testPathPattern=module.test
Linting
# Run eslint
npm run lint
# Fix auto-fixable issues
npm run lint -- --fix
# Type-aware linting (if configured)
npx eslint --ext .ts,.tsx src/
Formatting
# Format with prettier
npm run format
# Check without changing
npx prettier --check .
Project Structure
project/
├── src/
│ ├── index.ts
│ ├── types.ts
│ └── module.ts
├── tests/
│ └── module.test.ts
├── package.json
├── tsconfig.json
└── README.md
tsconfig.json Template
{
"compilerOptions": {
"target": "ES2022",
"module": "NodeNext",
"moduleResolution": "NodeNext",
"strict": true,
"esModuleInterop": true,
"skipLibCheck": true,
"forceConsistentCasingInFileNames": true,
"declaration": true,
"outDir": "./dist",
"rootDir": "./src"
},
"include": ["src/**/*"],
"exclude": ["node_modules", "dist"]
}
package.json Scripts
{
"scripts": {
"build": "tsc",
"test": "jest",
"lint": "eslint src/",
"format": "prettier --write .",
"typecheck": "tsc --noEmit",
"check": "npm run typecheck && npm run lint && npm run test"
}
}
TDD Cycle Commands
# RED: Write test, run to see it fail
npm test -- --testPathPattern=new_feature
# GREEN: Implement, run to see it pass
npm test -- --testPathPattern=new_feature
# REFACTOR: Clean up, ensure tests still pass
npm run check
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
forge-lang-c
C development standards including make, gcc/clang, valgrind, and cppcheck. Use when working with C files, Makefiles, or CMakeLists.txt.
forge-lang-terragrunt
Terragrunt wrapper for Terraform with DRY configurations. Enforces plan-before-apply workflow. Use when working with terragrunt.hcl files.
forge-lang-cpp
C++ development standards including make/cmake, g++/clang++, and static analysis. Use when working with C++ files (.cpp, .hpp, .cc, .hh).
forge-lang-rust
Rust development standards including cargo test, clippy, and rustfmt. Use when working with Rust files, Cargo.toml, or Rust tests.
forge-lang-ansible
Ansible automation safety practices. Enforces check-mode-first workflow. Use when working with playbooks, roles, or inventory files.
forge-lang-python
Python development standards including pytest, ruff, black, and mypy. Use when working with Python files, tests, or dependencies.
Didn't find tool you were looking for?