# Init tsconfig

> Init tsconfig is an open-source agent skill for developer tools. Guides an agent to lower VSCode tsserver memory use via tsconfig.json changes. It is available on Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose.

- **Kind:** Skill
- **Pricing:** Open source
- **Platforms:** Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf, Goose
- **Website:** https://github.com/ruan-cat/monorepo/tree/main/ai-plugins/low-frequency-skill/skills/init-tsconfig
- **Repository:** https://github.com/ruan-cat/monorepo
- **GitHub stars:** 5
- **License:** MIT
- **Skill name:** init-tsconfig
- **Collection:** https://github.com/ruan-cat/monorepo
- **Categories:** [developer tools](https://ai-powered.com/categories/developer-tools)
- **Listing updated:** 2026-12-04

## About

This skill walks an agent through trimming the memory footprint of the TypeScript language server in VSCode by adjusting tsconfig.json files. It asks the agent to first classify each project's layout (single app, solution-style root, composite child, monorepo package, extended preset, or a project to skip) because the same compiler key can be a no-op in the wrong place. Core changes include enabling incremental builds with a cache file under node_modules, skipping library type checks, and tightening include and exclude lists. Monorepo packages get an extra change limiting re-checks to direct dependents.

The workflow runs in five steps per repository: record a baseline type-check error count, check for existing settings before editing, confirm the original files are in git and that build artifacts are ignored, apply additive edits with comments, and compare error counts afterward. The guidance also covers a set of user-level editor settings that pair with the tsconfig changes, and a list of pitfalls such as include and exclude conflicts, shared cache file names between sibling configs, and avoiding bulk calls to the code CLI.

The skill expects a TypeScript or Vue project with a working type-check command, git, and access to the repository's tsconfig files. A detailed reference file with a multi-repository case study is included.

## When your agent uses it

> 通过 tsconfig.json 的合理配置降低 VSCode tsserver 的运行时内存占用，附 14 仓库实证策略矩阵与批量落地流程。当用户要求降低 tsserver 或 TypeScript 内存、优化 VSCode/IDE 内存占用、批量治理项目 tsconfig 时使用。

## What it can access

From a static check of the files on GitHub; nothing was run.

- [Instructions only, no scripts](https://github.com/ruan-cat/monorepo/tree/HEAD/ai-plugins/low-frequency-skill/skills/init-tsconfig)
- [License: MIT](https://github.com/ruan-cat/monorepo/tree/HEAD/ai-plugins/low-frequency-skill/skills/init-tsconfig)

## Features

- **Project shape classification:** Sorts each tsconfig into a known layout so the right keys are added in the right file.
- **Incremental build cache setup:** Enables incremental compilation with a tsbuildinfo cache stored under node_modules.
- **Include and exclude tightening:** Narrows the set of files the language server collects to reduce memory use.
- **Baseline-compare verification:** Compares type-check error counts before and after edits to confirm no regressions.
- **Editor settings companion:** Lists user-level TypeScript server settings that complement the tsconfig changes.
- **Batch repository pitfalls:** Covers common traps when applying the changes across many repositories, such as cache name collisions.

## Good for

- Reduce VSCode TypeScript server memory usage in a large project
- Add incremental build caching to several tsconfig files in a monorepo
- Audit a solution-style tsconfig and push settings into its child configs
- Apply consistent tsconfig memory tweaks across many repositories

## Install

### Claude Code

This skill ships in the `low-frequency-skill` plugin. In Claude Code, add the marketplace and install the plugin (it may include other skills too):

```sh
/plugin marketplace add ruan-cat/monorepo
/plugin install low-frequency-skill@ruan-cat-tools
```

Or copy only this skill to `~/.claude/skills/init-tsconfig`:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ruan-cat/monorepo.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/init-tsconfig &&
cp -R "$tmp/ai-plugins/low-frequency-skill/skills/init-tsconfig" ~/.claude/skills/init-tsconfig &&
rm -rf "$tmp"
```

For one project only, put the folder in `.claude/skills/init-tsconfig` inside it instead.

### Codex

Copy the skill folder to `~/.agents/skills/init-tsconfig` to use it in every repository:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ruan-cat/monorepo.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/init-tsconfig &&
cp -R "$tmp/ai-plugins/low-frequency-skill/skills/init-tsconfig" ~/.agents/skills/init-tsconfig &&
rm -rf "$tmp"
```

For one repository only, put the folder in `.agents/skills/init-tsconfig` inside it instead.

### Cursor

Copy the skill folder to `~/.cursor/skills/init-tsconfig` to use it in every project:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ruan-cat/monorepo.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/init-tsconfig &&
cp -R "$tmp/ai-plugins/low-frequency-skill/skills/init-tsconfig" ~/.cursor/skills/init-tsconfig &&
rm -rf "$tmp"
```

For one project only, put the folder in `.cursor/skills/init-tsconfig` inside it instead.

### Gemini CLI

Run in a terminal (add `--scope workspace` to install it for the current workspace only):

```sh
gemini skills install https://github.com/ruan-cat/monorepo.git --path ai-plugins/low-frequency-skill/skills/init-tsconfig
```

Or copy the folder to `~/.gemini/skills/init-tsconfig` yourself.

### VS Code

For GitHub Copilot in VS Code, copy the skill folder to `~/.copilot/skills/init-tsconfig`:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ruan-cat/monorepo.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/init-tsconfig &&
cp -R "$tmp/ai-plugins/low-frequency-skill/skills/init-tsconfig" ~/.copilot/skills/init-tsconfig &&
rm -rf "$tmp"
```

For one project only, put the folder in `.github/skills/init-tsconfig` inside it instead.

### Other agents

Get the folder:

```sh
git clone --depth 1 https://github.com/ruan-cat/monorepo.git
```

Then copy `monorepo/ai-plugins/low-frequency-skill/skills/init-tsconfig` into your agent's skills folder as `init-tsconfig`. Agents that support SKILL.md read one folder per skill.

## FAQ

### When does Init tsconfig trigger?

It is meant for requests to lower tsserver or TypeScript memory, optimize IDE memory use, or batch-manage project tsconfig files.

### Does Init tsconfig add tsconfig files where none exist?

No. Projects without a tsconfig, without TypeScript sources, or that are example scaffolds are skipped rather than created.

### Which tools does Init tsconfig need?

It relies on running tsc or the project's own typecheck script, plus git for checking the original files and ignore rules.

### Does Init tsconfig change build output?

The guidance adds caching and check-scope options and states it should not remove or rewrite existing settings, with error counts compared before and after.

### How do I install Init tsconfig in Claude Code?

Copy the skill folder from GitHub to ~/.claude/skills/init-tsconfig to use it in all your projects, or to .claude/skills/init-tsconfig in one project. Or install the low-frequency-skill plugin, which includes it: /plugin marketplace add ruan-cat/monorepo, then /plugin install low-frequency-skill@ruan-cat-tools.

### Does Init tsconfig run scripts?

No. It is instructions only, with no scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.

### Which AI agents can use Init tsconfig?

Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose. Each reads skills in the SKILL.md format from its own folder; the install steps on this page list them.

### What are the best alternatives to Init tsconfig?

The closest alternatives to Init tsconfig are Package linter, TypeScript best practices, Antfu, Init vscode and TypeScript.

## Where this comes from

- Description: from the skill's own SKILL.md.

## Alternatives

- [Package linter](https://ai-powered.com/skills/package-linter): Package linter is an open-source agent skill for developer tools.
- [TypeScript best practices](https://ai-powered.com/skills/typescript-best-practices): TypeScript best practices is an open-source agent skill for developer tools.
- [Antfu](https://ai-powered.com/skills/antfu): Antfu is an open-source agent skill for developer tools.
- [Init vscode](https://ai-powered.com/skills/init-vscode): Init vscode is an open-source agent skill for developer tools.
- [TypeScript](https://ai-powered.com/skills/typescript): TypeScript is an open-source agent skill for developer tools.
- [Marco code style](https://ai-powered.com/skills/marco-code-style): Marco code style is an open-source agent skill for developer tools.
- [Build tooling](https://ai-powered.com/skills/build-tooling): Build tooling is an open-source agent skill for developer tools.
- [Git workflow and versioning](https://ai-powered.com/skills/git-workflow-and-versioning): Git workflow and versioning is an open-source agent skill for developer tools.

---
Source: https://ai-powered.com/skills/init-tsconfig
