Skip to content

feat: VSCode環境の強化 - cSpell辞書、拡張機能、設定の追加 - #491

Merged
keito4 merged 2 commits into
mainfrom
feat/vscode-environment-enhancements
Feb 19, 2026
Merged

feat: VSCode環境の強化 - cSpell辞書、拡張機能、設定の追加#491
keito4 merged 2 commits into
mainfrom
feat/vscode-environment-enhancements

Conversation

@keito4

@keito4 keito4 commented Feb 19, 2026

Copy link
Copy Markdown
Owner

Summary

  • cspell.jsonを追加し、技術用語・拡張機能IDの辞書を登録
  • 便利なVSCode拡張機能(ErrorLens, GitLens, TODO Tree等)を推奨に追加
  • settings.jsonを強化(ブラケットペア、スティッキースクロール、TypeScript最適化等)

Test plan

  • VSCodeでファイルを開き、cSpellの警告が解消されていることを確認
  • 推奨拡張機能がインストール候補として表示されることを確認
  • settings.jsonの設定が正しく適用されることを確認

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Chores
    • Expanded VS Code extension recommendations and enabled editor features (bracket colorization, sticky scroll, inlay hints, linked editing, etc.).
    • Added comprehensive VS Code settings and per-language formatter preferences.
    • Added spell-check configuration with multilanguage support and a custom words dictionary.
    • Updated ignore settings to track the custom spell-check words file.

- cspell.json: 技術用語・拡張機能IDの辞書を追加
- extensions.json: ErrorLens, GitLens, TODO Tree等の便利な拡張機能を追加
- settings.json: ブラケットペア、スティッキースクロール、TypeScript最適化等を追加

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Feb 19, 2026

Copy link
Copy Markdown
📝 Walkthrough

Walkthrough

Expanded VSCode workspace configuration: added many extension recommendations, detailed editor and language settings, a cspell configuration with custom word list, and an exception in .gitignore to track the custom words file. All changes are configuration only.

Changes

Cohort / File(s) Summary
Extension recommendations
.vscode/extensions.json
Replaced the short recommendations array with a longer list (3 → 11 items). Only the recommendations array contents changed.
Editor & language settings
.vscode/settings.json
Added/updated extensive editor preferences (bracket colorization, linked editing, sticky scroll, inlay hints, minimap off), language-specific formatter selections and overrides, TypeScript preferences, file/search exclusions, and tool-specific settings (Prettier, Error Lens, TODO Tree, GitLens).
Spell-check config & custom words
cspell.json, .vscode/cspell-custom-words.txt
Added cspell.json with English/Japanese support, a custom-words dictionary, word list, ignore paths and regexes; introduced .vscode/cspell-custom-words.txt (referenced) as custom dictionary source.
Git ignore tweak
.gitignore
Added a negation rule to un-ignore .vscode/cspell-custom-words.txt so the custom words file is tracked.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Suggested labels

released, size/S

Poem

🐰 In a burrow of code I nibble and write,
Extensions and spelllists keep errors from sight.
Brackets in color, settings aligned,
A tidy small warren for each curious mind.

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main changes: adding cSpell dictionary, VSCode extensions, and settings configurations to enhance the VSCode environment.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feat/vscode-environment-enhancements

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@keito4

keito4 commented Feb 19, 2026

Copy link
Copy Markdown
Owner Author

🔍 AI Code Review (Local Hook)

Models: Codex (default) / Gemini (default)

🤖 Codex Review

指摘事項

  • cspell.json:6-10./.vscode/cspell-custom-words.txt を辞書として指定していますが、/.vscode に当該ファイルが存在しません。これにより cspell 実行時に辞書読み込み失敗(または自動追加ができない)になり、CI/ローカルのスペルチェックが壊れる可能性があります。対策は、空でもよいので /.vscode/cspell-custom-words.txt を追加するか、この辞書定義を削除してください。

判定: patch is incorrect
理由: 新規の cspell 設定が存在しない辞書ファイルに依存しており、ツール実行時に失敗しうるため。
信頼度: 0.33

✨ Gemini Review

はい、承知いたしました。Git diffのレビューを実施します。

発見事項

  1. 問題: cspellのカスタム辞書ファイルがリポジトリに含まれていない
    • ファイル: cspell.json
    • 行範囲: 9-12
    • 説明: 設定ファイル cspell.json でカスタム辞書として ./.vscode/cspell-custom-words.txt を指定していますが、このファイル自体はリポジトリに追加されていません。新しい開発者がプロジェクトをセットアップした際にファイルが存在せず、スペルチェック機能が意図通りに動作しない可能性があります。空の .vscode/cspell-custom-words.txt ファイルをリポジトリに追加することを推奨します。

全体的な評価

  • 判定: patch is incorrect
  • 理由: cspell.json の設定に不備があり、リポジトリに存在しない辞書ファイルを参照しています。これにより、開発者間でツールの挙動に差異が生まれ、開発者体験を損なう可能性があります。
  • 信頼度: 1.0

⚠️ 修正が必要です

上記のレビューで問題が指摘されています。修正してからマージしてください。


🤖 Generated by post_pr_ai_review.py hook

@claude

claude Bot commented Feb 19, 2026

Copy link
Copy Markdown
Contributor

Claude Code レビュー

概要

VSCode環境強化のPRとして全体的に有用な変更です。ただし、いくつか対応が必要な点があります。


🔴 バグ・問題点

1. 参照ファイルの欠落(要対応)

cspell.json.vscode/cspell-custom-words.txt を辞書として参照していますが、このファイルがPRに含まれていません。

// cspell.json
{
  "dictionaryDefinitions": [
    {
      "name": "custom-words",
      "path": "./.vscode/cspell-custom-words.txt",  // ← このファイルが存在しない
      "addWords": true
    }
  ]
}

cSpellが起動時にエラーまたは警告を出します。空のファイルでも追加するか、dictionaryDefinitions ごと削除して words 配列だけに集約することを推奨します。


🟡 改善推奨

2. source.organizeImports の副作用リスク

"editor.codeActionsOnSave": {
  "source.fixAll.eslint": "explicit",
  "source.organizeImports": "explicit"  // ← 追加
}

保存時に自動でimport順を変更するため、ESLintのimport-order設定や意図的な順序と競合する可能性があります。このリポジトリのeslint設定でimport-orderが管理されているか確認してください。競合する場合は削除か `"never"" に変更を推奨します。

3. プロジェクト特化型の拡張機能

"ms-azuretools.vscode-docker",    // Dockerを使わないプロジェクトには不要
"bradlc.vscode-tailwindcss"       // Tailwind CSSを使わないプロジェクトには不要

このリポジトリはクロスプロジェクトの設定テンプレートです。特定技術スタック依存の拡張機能を推奨一覧に入れると、Tailwind/Dockerを使わないリポジトリに展開した際にノイズになります。削除するか unwantedRecommendations への移動を検討してください。

4. グローバルな editor.wordWrap: "on"

"editor.wordWrap": "on"  // 全ファイルタイプに適用される

コードファイルでの折り返しはデバッグ時に視認性を下げる場合があります。[markdown] セクションにのみ設定済みなので、グローバル設定は削除して良いかもしれません(markdownには既に個別設定があります)。


🟢 軽微な指摘

5. 冗長な設定

// extensions.json
"unwantedRecommendations": []  // 空配列は不要
// settings.json - files.exclude
"**/.git": true  // VS Codeのデフォルトで既に除外済み

✅ 良い点

  • errorLens.excludeBySource: ["cSpell"] でcSpellの誤検知をErrorLensから除外しているのは実用的
  • gitlens.codeLens.enabled: false でパフォーマンスへの配慮あり
  • typescript.inlayHints の設定は開発体験向上に有効
  • search.exclude へのlock/build成果物除外は適切
  • [shellscript]defaultFormatter: null でshell scriptへの誤フォーマット防止

まとめ

優先度 件数
要対応(バグ) 1件
改善推奨 3件
軽微 2件

マージ前に .vscode/cspell-custom-words.txt の欠落を解消することを必須とします。 他の指摘はオプションですが対応を推奨します。

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🧹 Nitpick comments (4)
.vscode/extensions.json (2)

5-5: ms-vscode.vscode-typescript-next recommends nightly TypeScript to all contributors.

This extension installs pre-release TypeScript builds that can break editing/type-checking experience unpredictably. For a shared workspace config, consider removing it and instead pinning a stable TypeScript version in package.json, which all editors will pick up automatically.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.vscode/extensions.json at line 5, The workspace recommends the pre-release
extension "ms-vscode.vscode-typescript-next", which can introduce unstable
TypeScript behavior; remove that entry from .vscode/extensions.json and instead
add/pin a stable TypeScript version in package.json's devDependencies (e.g.,
"typescript": "<stable-version>") so editors use the project TypeScript; update
README or CONTRIBUTING to document using the pinned TypeScript and run npm/yarn
install so contributors pick up the stable toolchain.

5-5: ms-vscode.vscode-typescript-next recommends nightly TypeScript builds to all contributors.

This extension installs pre-release/nightly TypeScript versions that may introduce breaking language service changes, reducing editor stability for the whole team. Consider replacing it with the stable TypeScript SDK via ms-vscode.vscode-typescript or simply relying on the workspace's typescript package for type-checking.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.vscode/extensions.json at line 5, The workspace recommends the nightly
TypeScript extension "ms-vscode.vscode-typescript-next", which can introduce
unstable language-service changes; replace that entry with the stable
"ms-vscode.vscode-typescript" or remove it and rely on the project's
workspace/typescript package instead to ensure consistent, stable editor
behavior for all contributors.
cspell.json (2)

2-2: Schema URL is pinned to the mutable main branch.

The URL https://raw.githubusercontent.com/streetsidesoftware/cspell/main/... can change without notice. The latest stable cspell release is 9.6.4, so pin the schema to match the version in use.

♻️ Proposed fix — pin schema to a versioned tag
-  "$schema": "https://raw.githubusercontent.com/streetsidesoftware/cspell/main/packages/cspell-types/cspell.schema.json",
+  "$schema": "https://raw.githubusercontent.com/streetsidesoftware/cspell/cspell%409.6.4/packages/cspell-types/cspell.schema.json",
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@cspell.json` at line 2, The "$schema" entry in cspell.json is pinned to the
mutable main branch; update the schema URL to reference the stable cspell v9.6.4
tag instead (replace the current
https://raw.githubusercontent.com/streetsidesoftware/cspell/main/... URL with
the versioned tag URL for v9.6.4) so the schema is stable and matches the cspell
release used.

2-2: Schema URL is pinned to the mutable main branch.

https://raw.githubusercontent.com/streetsidesoftware/cspell/main/... can change at any time. Pin to a specific release tag (e.g., v9.6.4) so IDE validation stays stable.

♻️ Proposed fix — pin schema to a versioned release
-  "$schema": "https://raw.githubusercontent.com/streetsidesoftware/cspell/main/packages/cspell-types/cspell.schema.json",
+  "$schema": "https://raw.githubusercontent.com/streetsidesoftware/cspell/v9.6.4/packages/cspell-types/cspell.schema.json",
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@cspell.json` at line 2, The cspell.json "$schema" property is pointing at the
mutable 'main' branch URL; replace that URL with a versioned release tag (for
example change
"https://raw.githubusercontent.com/streetsidesoftware/cspell/main/packages/cspell-types/cspell.schema.json"
to use a specific tag such as
"https://raw.githubusercontent.com/streetsidesoftware/cspell/v9.6.4/packages/cspell-types/cspell.schema.json")
so the schema is pinned and IDE validation remains stable.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@cspell.json`:
- Around line 6-11: The cspell.json references a custom word list at
"./.vscode/cspell-custom-words.txt" under "dictionaryDefinitions" with
"addWords": true, but that file is missing; create and commit an empty
.vscode/cspell-custom-words.txt file (or add initial words) to the repo so
cSpell and the VSCode "Add Word" action can write to it without warnings, then
ensure the file is tracked in git.
- Around line 6-11: The cspell configuration in cspell.json references a
non-existent custom dictionary path ("dictionaryDefinitions" entry with "path":
"./.vscode/cspell-custom-words.txt" and "addWords": true); create the file
.vscode/cspell-custom-words.txt (an empty file is fine) so cSpell no longer
warns and user-added words can be persisted.

---

Nitpick comments:
In @.vscode/extensions.json:
- Line 5: The workspace recommends the pre-release extension
"ms-vscode.vscode-typescript-next", which can introduce unstable TypeScript
behavior; remove that entry from .vscode/extensions.json and instead add/pin a
stable TypeScript version in package.json's devDependencies (e.g., "typescript":
"<stable-version>") so editors use the project TypeScript; update README or
CONTRIBUTING to document using the pinned TypeScript and run npm/yarn install so
contributors pick up the stable toolchain.
- Line 5: The workspace recommends the nightly TypeScript extension
"ms-vscode.vscode-typescript-next", which can introduce unstable
language-service changes; replace that entry with the stable
"ms-vscode.vscode-typescript" or remove it and rely on the project's
workspace/typescript package instead to ensure consistent, stable editor
behavior for all contributors.

In `@cspell.json`:
- Line 2: The "$schema" entry in cspell.json is pinned to the mutable main
branch; update the schema URL to reference the stable cspell v9.6.4 tag instead
(replace the current
https://raw.githubusercontent.com/streetsidesoftware/cspell/main/... URL with
the versioned tag URL for v9.6.4) so the schema is stable and matches the cspell
release used.
- Line 2: The cspell.json "$schema" property is pointing at the mutable 'main'
branch URL; replace that URL with a versioned release tag (for example change
"https://raw.githubusercontent.com/streetsidesoftware/cspell/main/packages/cspell-types/cspell.schema.json"
to use a specific tag such as
"https://raw.githubusercontent.com/streetsidesoftware/cspell/v9.6.4/packages/cspell-types/cspell.schema.json")
so the schema is pinned and IDE validation remains stable.

Comment thread cspell.json
Comment on lines +6 to +11
"dictionaryDefinitions": [
{
"name": "custom-words",
"path": "./.vscode/cspell-custom-words.txt",
"addWords": true
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

fd --type f "cspell-custom-words.txt"

Repository: keito4/config

Length of output: 39


🏁 Script executed:

# Verify cspell.json exists and contains the configuration mentioned in the review
cat cspell.json | head -20

Repository: keito4/config

Length of output: 529


cspell-custom-words.txt is referenced but not committed.

./.vscode/cspell-custom-words.txt does not exist in the repository. cSpell will emit a warning on every run, and with "addWords": true, attempts to persist new words via the "Add Word" VSCode command will silently fail until the file exists. Commit an empty file alongside this config.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@cspell.json` around lines 6 - 11, The cspell.json references a custom word
list at "./.vscode/cspell-custom-words.txt" under "dictionaryDefinitions" with
"addWords": true, but that file is missing; create and commit an empty
.vscode/cspell-custom-words.txt file (or add initial words) to the repo so
cSpell and the VSCode "Add Word" action can write to it without warnings, then
ensure the file is tracked in git.

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

fd --type f "cspell-custom-words.txt"

Repository: keito4/config

Length of output: 39


Add the missing .vscode/cspell-custom-words.txt file.

The file referenced in cspell.json (line 9) does not exist in the repository. This will cause cSpell to emit a warning on every invocation, and addWords: true will fail to persist user-added words. Create an empty .vscode/cspell-custom-words.txt file to resolve this.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@cspell.json` around lines 6 - 11, The cspell configuration in cspell.json
references a non-existent custom dictionary path ("dictionaryDefinitions" entry
with "path": "./.vscode/cspell-custom-words.txt" and "addWords": true); create
the file .vscode/cspell-custom-words.txt (an empty file is fine) so cSpell no
longer warns and user-added words can be persisted.

- cspell-custom-words.txt を追加(辞書ファイル欠落の修正)
- .gitignore に cspell-custom-words.txt の例外を追加
- source.organizeImports を削除(ESLintとの競合リスク回避)
- プロジェクト依存拡張機能(Docker/Tailwind)を削除
- グローバル editor.wordWrap を削除(markdown個別設定で十分)
- 冗長な設定を削除(unwantedRecommendations, .git除外)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@claude

claude Bot commented Feb 19, 2026

Copy link
Copy Markdown
Contributor

Claude Code レビュー

総評

VSCode 開発環境の標準化として方向性は適切です。ただし、いくつか確認・改善すべき点があります。


🔴 要対応

1. cspell.json"language": "ja" は機能しない可能性

cSpell には日本語辞書が組み込まれていません。"language": "en,ja" と設定しても、@cspell/dict-ja パッケージがインストールされていなければ警告が発生するか、設定が無視されます。

対応案:

  • 日本語辞書が不要であれば "language": "en" に変更する
  • または devDependencies@cspell/dict-ja を追加し、dictionaries"ja" を明示的に指定する

🟡 検討事項

2. errorLens.excludeBySource: ["cSpell"] の意図確認

ErrorLens のインライン表示から cSpell の警告を除外する設定になっています。streetsidesoftware.code-spell-checker を推奨拡張機能に追加しているにもかかわらず、ErrorLens からは見えなくなります(Problems パネルには引き続き表示されます)。

  • ノイズを減らす意図であれば意図的な設定として明示的なコメントがあると良い
  • cSpell の警告もインライン表示したい場合はこの行を削除

3. editor.minimap.enabled: false はチーム共有設定として要検討

ミニマップの表示は開発者の好みが分かれます。共有設定で無効化すると、ミニマップを使いたい開発者が毎回ローカル設定で上書きする必要が生じます。

対応案: この設定を settings.json から削除し、個人設定に委ねる

4. typescript.preferences.importModuleSpecifier: "relative" の影響範囲

絶対インポートパス(パスエイリアス @/... 等)を使うプロジェクトが混在する場合、この設定が自動インポートの挙動を強制的に相対パスに変更します。モノレポ構成では影響が大きい可能性があります。


✅ 良い点

  • files.exclude / search.exclude: node_modules, .next, dist, ロックファイル等の除外は検索パフォーマンス向上に直結する実用的な設定
  • [shellscript]: { "editor.defaultFormatter": null }: Prettier がシェルスクリプトを誤ってフォーマットするのを防ぐ正しい設定
  • TypeScript inlay hints: parameterNamesfunctionLikeReturnTypes の設定は可読性向上に有効
  • gitlens.codeLens.enabled: false: GitLens の CodeLens は重いため、オフにしてカレント行のブレームのみ残すのは妥当
  • 拡張機能の選定: ErrorLens, pretty-ts-errors, TodoTree はチーム全体の開発効率向上に有用
  • .gitignore への cspell-custom-words.txt 追加: 共有辞書をバージョン管理するのは適切

補足

テストプランは手動確認となっていますが、これは VSCode の設定変更として適切です。CI での自動検証は困難なため、チェックリストの各項目を実際に確認することを推奨します。

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (1)
.vscode/settings.json (1)

13-15: Prefer the modern string enum value over the legacy boolean for editor.quickSuggestions.

"strings": true is the old boolean format. The sub-properties strings, comments, and other now accept on, inline, off in addition to true and false. Both still work, but the setting is inconsistent with the markdown override at lines 65–68, which already uses the modern "off" string form.

♻️ Proposed fix
-  "editor.quickSuggestions": {
-    "strings": true
-  },
+  "editor.quickSuggestions": {
+    "strings": "on"
+  },
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.vscode/settings.json around lines 13 - 15, Update the
editor.quickSuggestions sub-property to use the modern string enum instead of a
boolean: replace the boolean value for "strings" under the
editor.quickSuggestions setting with the equivalent string (e.g. "on") so it
matches the modern format used elsewhere (see the editor.quickSuggestions ->
strings property and the markdown override that uses "off"); leave other
sub-properties unchanged.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Nitpick comments:
In @.vscode/settings.json:
- Around line 13-15: Update the editor.quickSuggestions sub-property to use the
modern string enum instead of a boolean: replace the boolean value for "strings"
under the editor.quickSuggestions setting with the equivalent string (e.g. "on")
so it matches the modern format used elsewhere (see the editor.quickSuggestions
-> strings property and the markdown override that uses "off"); leave other
sub-properties unchanged.

@keito4
keito4 merged commit bdf37d5 into main Feb 19, 2026
13 checks passed
github-actions Bot added a commit that referenced this pull request Feb 19, 2026
feat/project-type-presets (#490) と feat/vscode-environment-enhancements (#491)
のマージにより生じたコンフリクトを手動で解消。

- .claude/commands/setup-new-repo.md: --type/--interactive オプション、Step 3.5
  (プロジェクトタイプ検出)、Step 9.5 (skills/plugins設定) を追加
- docs/setup/README.md: project-presets.json への参照と Note を追加
- .devcontainer/codespaces/devcontainer.json: CLAUDE_CONFIG_DIR を追加
- .devcontainer/templates/project-presets.json: 新規作成(プロジェクトプリセット定義)
- .gitignore: cspell-custom-words.txt と .claude-data/ を追加
- .vscode/extensions.json: 推奨拡張機能を追加
- .vscode/settings.json: 詳細なエディタ設定を追加
- cspell.json, .vscode/cspell-custom-words.txt: スペルチェック設定を追加

Co-authored-by: keito4 <keito4@users.noreply.github.com>
@github-actions

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 1.80.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@github-actions github-actions Bot added the released リリース済み label Feb 20, 2026
@keito4
keito4 deleted the feat/vscode-environment-enhancements branch March 1, 2026 09:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

released リリース済み

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant