# 開発者ツール・ライブラリ：推奨構成

> 作成：2026年9月。前提：PHPは選択肢から除外。個人の既定であり、プロジェクト固有の要件・既存資産・チームの制約と食い違う場合はそちらを優先する。
> バージョン番号は書いていない。採用時は各ツールの最新安定版を確認して使う。料金も記載していないので、各サービスの最新の料金ページで確認する。

## 推奨：Rust
- 近年の高速な開発ツールの主流で、WebAssemblyやネイティブ拡張として他言語に組み込める（§2-9）

## 構成

### 構成
| レイヤー | 採用 |
|---|---|
| 言語 | **Rust** |
| WebAssembly | **wasm-bindgen＋wasm-pack** |
| Node.jsから呼ぶ | **napi-rs** |
| Pythonから呼ぶ | **PyO3＋maturin** |
| テスト | **cargo-nextest** |
| ベンチマーク | **criterion** |
| 配布 | **cargo-dist** |

## 運用の内訳
- 自分で書く：wasm-bindgen、wasm-pack、napi-rs、PyO3、maturin、cargo-nextest、criterion、cargo-dist

## §26-1 共通の準備

```bash
# 言語・ツールのバージョン固定（使う言語だけ）
mise use node@lts pnpm@latest
mise use go@latest
mise use ruby@latest
mise use python@latest uv@latest

# Gitフックと依存更新
pnpm add -D lefthook && pnpm exec lefthook install
# renovate.json を置き、GitHubでRenovateアプリを有効化する
```

## §26-11 その他の言語

```bash
# Rust（Web API）
cargo new app && cd app
cargo add axum serde --features serde/derive
cargo add tokio --features full
cargo add sqlx --features runtime-tokio,postgres
# Rust（デスクトップ）
pnpm create tauri-app@latest
# Kotlin（Spring Boot）
curl https://start.spring.io/starter.zip \
  -d language=kotlin -d type=gradle-project-kotlin \
  -d dependencies=web,jooq,flyway,postgresql,actuator \
  -o app.zip
# C#（ASP.NET Core）
dotnet new webapi -n App
```

## 次に読む
- §2-9: https://stackbook.kom3da.dev/s/2.md（「### 2-9.」の節）
- §2-5: https://stackbook.kom3da.dev/s/2.md（「### 2-5.」の節）
- §23: https://stackbook.kom3da.dev/s/23.md
- §24: https://stackbook.kom3da.dev/s/24.md
- §25: https://stackbook.kom3da.dev/s/25.md
