bundle-size-optimization
Reduce JavaScript and CSS bundle sizes through code splitting, tree shaking, and optimization techniques. Improve load times and overall application performance.
下記のコマンドをコピーしてターミナル(Mac/Linux)または PowerShell(Windows)に貼り付けてください。 ダウンロード → 解凍 → 配置まで全自動。
mkdir -p ~/.claude/skills && cd ~/.claude/skills && curl -L -o bundle-size-optimization.zip https://jpskill.com/download/21352.zip && unzip -o bundle-size-optimization.zip && rm bundle-size-optimization.zip
$d = "$env:USERPROFILE\.claude\skills"; ni -Force -ItemType Directory $d | Out-Null; iwr https://jpskill.com/download/21352.zip -OutFile "$d\bundle-size-optimization.zip"; Expand-Archive "$d\bundle-size-optimization.zip" -DestinationPath $d -Force; ri "$d\bundle-size-optimization.zip"
完了後、Claude Code を再起動 → 普通に「動画プロンプト作って」のように話しかけるだけで自動発動します。
💾 手動でダウンロードしたい(コマンドが難しい人向け)
- 1. 下の青いボタンを押して
bundle-size-optimization.zipをダウンロード - 2. ZIPファイルをダブルクリックで解凍 →
bundle-size-optimizationフォルダができる - 3. そのフォルダを
C:\Users\あなたの名前\.claude\skills\(Win)または~/.claude/skills/(Mac)へ移動 - 4. Claude Code を再起動
⚠️ ダウンロード・利用は自己責任でお願いします。当サイトは内容・動作・安全性について責任を負いません。
🎯 このSkillでできること
下記の説明文を読むと、このSkillがあなたに何をしてくれるかが分かります。Claudeにこの分野の依頼をすると、自動で発動します。
📦 インストール方法 (3ステップ)
- 1. 上の「ダウンロード」ボタンを押して .skill ファイルを取得
- 2. ファイル名の拡張子を .skill から .zip に変えて展開(macは自動展開可)
- 3. 展開してできたフォルダを、ホームフォルダの
.claude/skills/に置く- · macOS / Linux:
~/.claude/skills/ - · Windows:
%USERPROFILE%\.claude\skills\
- · macOS / Linux:
Claude Code を再起動すれば完了。「このSkillを使って…」と話しかけなくても、関連する依頼で自動的に呼び出されます。
詳しい使い方ガイドを見る →- 最終更新
- 2026-05-18
- 取得日時
- 2026-05-18
- 同梱ファイル
- 5
📖 Skill本文(日本語訳)
※ 原文(英語/中国語)を Gemini で日本語化したものです。Claude 自身は原文を読みます。誤訳がある場合は原文をご確認ください。
バンドルサイズの最適化
目次
概要
バンドルサイズが小さいほど、ダウンロード、パース、実行が高速になり、特に低速なネットワークでは体感パフォーマンスが劇的に向上します。
使用する場面
- ビルドプロセスの最適化
- デプロイ前のバンドル分析
- パフォーマンスベースラインの改善
- モバイルパフォーマンスへの注力
- 新しい依存関係を追加した後
クイックスタート
最小限の動作例:
// Analyze bundle composition
class BundleAnalysis {
analyzeBundle() {
return {
tools: [
"webpack-bundle-analyzer",
"Source Map Explorer",
"Bundle Buddy",
"Bundlephobia",
],
metrics: {
total_size: "850KB gzipped",
main_js: "450KB",
main_css: "120KB",
vendor: "250KB",
largest_lib: "moment.js (67KB)",
},
breakdown: {
react: "85KB (10%)",
lodash: "45KB (5%)",
moment: "67KB (8%)",
other: "653KB (77%)",
},
};
// ... (see reference guides for full implementation)
リファレンスガイド
references/ ディレクトリにある詳細な実装:
| ガイド | 内容 |
|---|---|
| バンドル分析 | バンドル分析 |
| 最適化手法 | 最適化手法 |
| 実装戦略 | 実装戦略 |
| ベストプラクティス | ベストプラクティス |
ベストプラクティス
✅ 実施すべきこと
- 確立されたパターンと慣例に従う
- クリーンで保守しやすいコードを書く
- 適切なドキュメントを追加する
- デプロイ前に徹底的にテストする
❌ 実施すべきでないこと
- テストや検証を省略する
- エラー処理を無視する
- 設定値をハードコードする
📜 原文 SKILL.md(Claudeが読む英語/中国語)を展開
Bundle Size Optimization
Table of Contents
Overview
Smaller bundles download faster, parse faster, and execute faster, dramatically improving perceived performance especially on slower networks.
When to Use
- Build process optimization
- Bundle analysis before deployment
- Performance baseline improvement
- Mobile performance focus
- After adding new dependencies
Quick Start
Minimal working example:
// Analyze bundle composition
class BundleAnalysis {
analyzeBundle() {
return {
tools: [
"webpack-bundle-analyzer",
"Source Map Explorer",
"Bundle Buddy",
"Bundlephobia",
],
metrics: {
total_size: "850KB gzipped",
main_js: "450KB",
main_css: "120KB",
vendor: "250KB",
largest_lib: "moment.js (67KB)",
},
breakdown: {
react: "85KB (10%)",
lodash: "45KB (5%)",
moment: "67KB (8%)",
other: "653KB (77%)",
},
};
// ... (see reference guides for full implementation)
Reference Guides
Detailed implementations in the references/ directory:
| Guide | Contents |
|---|---|
| Bundle Analysis | Bundle Analysis |
| Optimization Techniques | Optimization Techniques |
| Implementation Strategy | Implementation Strategy |
| Best Practices | Best Practices |
Best Practices
✅ DO
- Follow established patterns and conventions
- Write clean, maintainable code
- Add appropriate documentation
- Test thoroughly before deploying
❌ DON'T
- Skip testing or validation
- Ignore error handling
- Hard-code configuration values
同梱ファイル
※ ZIPに含まれるファイル一覧。`SKILL.md` 本体に加え、参考資料・サンプル・スクリプトが入っている場合があります。
- 📄 SKILL.md (2,160 bytes)
- 📎 references/best-practices.md (411 bytes)
- 📎 references/bundle-analysis.md (1,431 bytes)
- 📎 references/implementation-strategy.md (881 bytes)
- 📎 references/optimization-techniques.md (1,076 bytes)