vibes-plug 1.0.0 → 2.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (123) hide show
  1. package/.github/workflows/publish.yml +20 -0
  2. package/AGENTS.md +66 -0
  3. package/BLUEPRINT.md +152 -60
  4. package/CHANGELOG.md +50 -0
  5. package/README.md +346 -194
  6. package/package.json +25 -25
  7. package/plugin.json +1 -1
  8. package/skills/ai-cost-token-optimizer/SKILL.md +52 -0
  9. package/skills/ai-llm-integration-expert/SKILL.md +180 -162
  10. package/skills/api-design-expert/SKILL.md +314 -310
  11. package/skills/app-analyzer-optimizer/SKILL.md +193 -189
  12. package/skills/apple-ecosystem-expert/SKILL.md +142 -0
  13. package/skills/async-queue-temporal-expert/SKILL.md +54 -0
  14. package/skills/authentication-identity-expert/SKILL.md +251 -20
  15. package/skills/auto-doc-updater/SKILL.md +214 -204
  16. package/skills/autonomous-chaos-monkey/SKILL.md +63 -0
  17. package/skills/autonomous-red-teamer/SKILL.md +59 -0
  18. package/skills/autonomous-swarm-director/SKILL.md +69 -0
  19. package/skills/autonomous-tdd-debugger/SKILL.md +65 -0
  20. package/skills/bootstrap-to-modern/SKILL.md +90 -86
  21. package/skills/brainstorming/SKILL.md +373 -353
  22. package/skills/browser-automation-expert/SKILL.md +46 -0
  23. package/skills/ci-cd-devops-architect/SKILL.md +72 -45
  24. package/skills/cloud-hosting-expert/SKILL.md +244 -244
  25. package/skills/coderabbit/SKILL.md +192 -192
  26. package/skills/cron-scheduler-expert/SKILL.md +298 -0
  27. package/skills/data-telemetry-expert/SKILL.md +213 -213
  28. package/skills/database-orm-expert/SKILL.md +294 -294
  29. package/skills/dependency-upgrade-migrator/SKILL.md +295 -0
  30. package/skills/design-system-architect/SKILL.md +27 -10
  31. package/skills/doku-mcp-server/SKILL.md +251 -0
  32. package/skills/doku-payment-gateway/SKILL.md +227 -0
  33. package/skills/e2e-testing-expert/SKILL.md +315 -315
  34. package/skills/edge-serverless-db-expert/SKILL.md +43 -0
  35. package/skills/email-notification-expert/SKILL.md +362 -0
  36. package/skills/error-resilience-expert/SKILL.md +480 -0
  37. package/skills/event-driven-architect/SKILL.md +81 -81
  38. package/skills/feature-flag-analytics-expert/SKILL.md +46 -0
  39. package/skills/file-upload-media-expert/SKILL.md +431 -0
  40. package/skills/form-validation-expert/SKILL.md +401 -0
  41. package/skills/fullstack-expert/SKILL.md +202 -202
  42. package/skills/fullstack-expert/references/api_design_guide.md +466 -466
  43. package/skills/fullstack-expert/references/multi_language_backend.md +528 -528
  44. package/skills/fullstack-expert/scripts/api_contract_validator.py +253 -253
  45. package/skills/fullstack-expert/scripts/architecture_analyzer.py +326 -326
  46. package/skills/gemini-agent-booster/SKILL.md +135 -135
  47. package/skills/global-a11y-i18n-expert/SKILL.md +81 -81
  48. package/skills/glsl-shader-expert/SKILL.md +101 -0
  49. package/skills/go-programming-expert/SKILL.md +295 -295
  50. package/skills/graphql-apollo-expert/SKILL.md +108 -0
  51. package/skills/hig/SKILL.md +188 -188
  52. package/skills/hyper-context-synthesizer/SKILL.md +55 -0
  53. package/skills/js-backend-expert/SKILL.md +34 -9
  54. package/skills/legacy-code-translator/SKILL.md +65 -0
  55. package/skills/llm-cost-arbitrage-router/SKILL.md +59 -0
  56. package/skills/logging-error-tracking-expert/SKILL.md +338 -0
  57. package/skills/mcp-client-orchestrator/SKILL.md +70 -0
  58. package/skills/mcp-server-architect/SKILL.md +194 -194
  59. package/skills/micro-frontend-architect/SKILL.md +106 -0
  60. package/skills/mobile-expo-expert/SKILL.md +186 -186
  61. package/skills/mobile-push-notification-expert/SKILL.md +51 -0
  62. package/skills/monday-design-aesthetic/SKILL.md +67 -67
  63. package/skills/monorepo-architect/SKILL.md +227 -227
  64. package/skills/mpa-orchestrator/SKILL.md +101 -101
  65. package/skills/multi-agent-orchestration/SKILL.md +234 -234
  66. package/skills/multiple-entry-points/SKILL.md +55 -55
  67. package/skills/mvc-expert/SKILL.md +231 -231
  68. package/skills/payment-gateway-expert/SKILL.md +45 -45
  69. package/skills/performance-web-vitals/SKILL.md +332 -332
  70. package/skills/post-quantum-crypto-migrator/SKILL.md +57 -0
  71. package/skills/prd-architect/SKILL.md +201 -191
  72. package/skills/proactive-background-watcher/SKILL.md +62 -0
  73. package/skills/production-ready-hardener/PRODUCTION_READINESS_REPORT.md +67 -0
  74. package/skills/production-ready-hardener/SKILL.md +173 -186
  75. package/skills/production-ready-hardener/references/production_checklist.md +161 -161
  76. package/skills/production-ready-hardener/scripts/production_readiness_scanner.py +881 -875
  77. package/skills/project-context-mapper/SKILL.md +79 -0
  78. package/skills/python-programming-expert/SKILL.md +263 -132
  79. package/skills/rate-limit-abuse-prevention/SKILL.md +371 -0
  80. package/skills/realtime-collaboration-expert/SKILL.md +45 -45
  81. package/skills/rust-programming-expert/SKILL.md +235 -235
  82. package/skills/saas-billing/SKILL.md +377 -377
  83. package/skills/saas-multi-tenant/SKILL.md +251 -237
  84. package/skills/saas-mvp-launcher/SKILL.md +10 -0
  85. package/skills/saas-transformer/SKILL.md +187 -144
  86. package/skills/saas-transformer/references/billing_integration_guide.md +401 -401
  87. package/skills/saas-transformer/references/feature_gating_patterns.md +137 -137
  88. package/skills/saas-transformer/references/saas_transformation_checklist.md +121 -121
  89. package/skills/saas-transformer/scripts/saas_transformation_scanner.py +39 -29
  90. package/skills/scalability-clean-code/SKILL.md +229 -229
  91. package/skills/self-evolving-memory-graph/SKILL.md +75 -0
  92. package/skills/self-healing-cloud-orchestrator/SKILL.md +57 -0
  93. package/skills/senior-frontend/SKILL.md +161 -161
  94. package/skills/senior-fullstack/SKILL.md +167 -167
  95. package/skills/seo/SKILL.md +235 -225
  96. package/skills/seo-geo/SKILL.md +188 -188
  97. package/skills/session-context-loader/SKILL.md +77 -0
  98. package/skills/session-handoff-resume/SKILL.md +158 -158
  99. package/skills/skill_baru/SKILL.md +172 -147
  100. package/skills/spa-orchestrator/SKILL.md +288 -288
  101. package/skills/state-management-expert/SKILL.md +272 -272
  102. package/skills/supabase-security-expert/SKILL.md +243 -243
  103. package/skills/tailwind-expert/SKILL.md +188 -188
  104. package/skills/tanstack-query-expert/SKILL.md +199 -199
  105. package/skills/token-saver/SKILL.md +119 -111
  106. package/skills/typescript-expert/SKILL.md +324 -279
  107. package/skills/ui-components-expert/SKILL.md +263 -46
  108. package/skills/ui-ux-pro-max/SKILL.md +202 -201
  109. package/skills/ui-ux-pro-max/scripts/__pycache__/core.cpython-310.pyc +0 -0
  110. package/skills/ui-ux-pro-max/scripts/__pycache__/design_system.cpython-310.pyc +0 -0
  111. package/skills/ui_ux_expert/SKILL.md +17 -6
  112. package/skills/vector-db-rag-expert/SKILL.md +52 -0
  113. package/skills/vibe-code-gardener/SKILL.md +181 -173
  114. package/skills/visual-qa-vision-agent/SKILL.md +65 -0
  115. package/skills/vue-frontend-expert/SKILL.md +126 -0
  116. package/skills/web-3d-graphics-expert/SKILL.md +131 -0
  117. package/skills/web-game-engine-expert/SKILL.md +96 -0
  118. package/skills/web-scraper/SKILL.md +207 -205
  119. package/skills/website-design-cloner/SKILL.md +174 -0
  120. package/skills/webxr-ar-vr-expert/SKILL.md +117 -0
  121. package/skills/zero-to-prod-orchestrator/SKILL.md +206 -180
  122. package/skills/zero-trust-secret-vault/SKILL.md +40 -0
  123. package/vibes-swarm-demo.gif +0 -0
@@ -1,189 +1,193 @@
1
- ---
2
- name: app-analyzer-optimizer
3
- description: "Deeply analyzes application architecture and structure to perform audit, bottleneck detection, and code/performance optimization / Mempelajari arsitektur dan struktur aplikasi secara mendalam untuk melakukan audit, deteksi bottleneck, serta optimasi performa dan kode."
4
- author: "Roedy Rustam"
5
- ---
6
-
7
- # App Analyzer & Optimizer (2026 Edition)
8
-
9
- [English](#english) | [Bahasa Indonesia](#bahasa-indonesia)
10
-
11
- ---
12
-
13
- <a name="english"></a>
14
- ## English
15
-
16
- ### Description
17
- Deep application analysis and optimization skill. Performs architectural audits, bottleneck detection, bundle analysis, database query profiling, and AI-assisted code review across Next.js, React, Node.js, Go, Python, and Rust applications.
18
-
19
- ### Trigger Conditions
20
- - Auditing an existing codebase for architectural issues or technical debt.
21
- - Detecting performance bottlenecks (slow API routes, large bundles, N+1 queries).
22
- - Analyzing bundle size and suggesting code splitting opportunities.
23
- - Reviewing code quality (complexity, duplication, dead code).
24
- - Using AI-assisted tools to accelerate code review and analysis.
25
-
26
- ### Analysis Protocol (5 Phases)
27
-
28
- #### Phase 1: Architecture Discovery
29
- ```bash
30
- # Map the entire project structure
31
- find . -type f -name "*.ts" -o -name "*.tsx" -o -name "*.go" | head -100
32
- # Count lines per file (find largest files)
33
- find . -name "*.ts" -exec wc -l {} + | sort -rn | head -20
34
- # Find circular dependencies (TypeScript/JS)
35
- npx madge --circular --extensions ts,tsx src/
36
- ```
37
-
38
- #### Phase 2: Bundle Analysis (Next.js / Vite)
39
- ```bash
40
- # Next.js bundle analyzer
41
- ANALYZE=true next build
42
-
43
- # Or install dedicated tool
44
- npx @next/bundle-analyzer
45
-
46
- # Vite bundle visualization
47
- npx vite-bundle-visualizer
48
-
49
- # Check for duplicate dependencies
50
- npx depcheck
51
- npx bundle-phobia-cli check package.json
52
- ```
53
-
54
- Key bundle red flags:
55
- - Any single chunk > 500KB (uncompressed).
56
- - Importing entire libraries (`import _ from 'lodash'` vs `import debounce from 'lodash/debounce'`).
57
- - Moment.js (replace with `date-fns` or `Temporal`).
58
- - `node_modules` leaking into client bundle.
59
-
60
- #### Phase 3: Database Query Analysis
61
- ```sql
62
- -- PostgreSQL: Find slow queries
63
- SELECT query, mean_exec_time, calls, total_exec_time
64
- FROM pg_stat_statements
65
- ORDER BY mean_exec_time DESC
66
- LIMIT 20;
67
-
68
- -- Find missing indexes (sequential scans on large tables)
69
- SELECT schemaname, tablename, attname, n_distinct, correlation
70
- FROM pg_stats
71
- WHERE tablename = 'your_table'
72
- ORDER BY n_distinct DESC;
73
-
74
- -- Detect N+1 queries: Enable query logging
75
- -- In Drizzle:
76
- const db = drizzle(client, { logger: true });
77
- -- In Prisma:
78
- DATABASE_URL="...?connection_limit=5" prisma studio
79
- ```
80
-
81
- #### Phase 4: AI-Assisted Code Review
82
- Use AI tools to accelerate analysis:
83
-
84
- | Tool | Purpose |
85
- |---|---|
86
- | **CodeRabbit** | Automated PR review, pattern detection |
87
- | **Sourcegraph Cody** | Codebase-wide semantic search and explanation |
88
- | **GitHub Copilot** | Inline suggestions and refactoring |
89
- | **Cursor / Windsurf** | AI IDE with full-repo context |
90
-
91
- AI review prompts for Gemini Agent:
92
- ```
93
- Analyze all files in src/features/ and identify:
94
- 1. Functions longer than 30 lines
95
- 2. Duplicated business logic across files
96
- 3. Missing error handling in async functions
97
- 4. Components that directly call APIs (violating separation of concerns)
98
- ```
99
-
100
- #### Phase 5: Performance Profiling
101
-
102
- **Frontend (React / Next.js):**
103
- ```bash
104
- # React DevTools Profiler — identify render bottlenecks
105
- # Chrome DevTools > Performance tab > Record interaction
106
-
107
- # Lighthouse CI — automated CWV tracking
108
- npm install -g @lhci/cli
109
- lhci autorun
110
- ```
111
-
112
- **Backend (Node.js):**
113
- ```bash
114
- # Built-in Node.js profiler
115
- node --prof server.js
116
- node --prof-process isolate-*.log > processed.txt
117
-
118
- # Clinic.js — flamegraph, bubble chart, doctor
119
- npm install -g clinic
120
- clinic doctor -- node server.js
121
- clinic flame -- node server.js
122
- ```
123
-
124
- **Go:**
125
- ```bash
126
- # Built-in pprof profiler
127
- go tool pprof http://localhost:6060/debug/pprof/profile?seconds=30
128
- go tool pprof -http=:8080 profile.out
129
- ```
130
-
131
- ### Common Bottleneck Patterns & Fixes
132
-
133
- | Bottleneck | Symptom | Fix |
134
- |---|---|---|
135
- | N+1 queries | DB calls proportional to list length | Add `.include()` / JOIN or DataLoader |
136
- | Missing indexes | Slow queries on filtered columns | `CREATE INDEX CONCURRENTLY` |
137
- | Unoptimized images | Large LCP, slow page load | Next.js `<Image>`, WebP, lazy loading |
138
- | Over-fetching | Fetching full objects when only 1 field needed | Select specific columns |
139
- | No pagination | Fetching entire tables | Add `LIMIT/OFFSET` or cursor pagination |
140
- | Blocking main thread | High INP, unresponsive UI | `useTransition`, web workers |
141
- | No caching | Same data fetched repeatedly | Redis, React Query staleTime, HTTP cache |
142
- | Bundle bloat | Large JS payload | Tree-shaking, code splitting, lazy imports |
143
-
144
- ---
145
-
146
- <a name="bahasa-indonesia"></a>
147
- ## Bahasa Indonesia
148
-
149
- ### Deskripsi
150
- Skill analisis dan optimasi aplikasi mendalam. Melakukan audit arsitektur, deteksi bottleneck, analisis bundle, profiling query database, dan code review berbantuan AI di aplikasi Next.js, React, Node.js, Go, Python, dan Rust.
151
-
152
- ### Kondisi Pemicu
153
- - Mengaudit codebase yang ada untuk masalah arsitektur atau hutang teknis.
154
- - Mendeteksi bottleneck performa (rute API lambat, bundle besar, query N+1).
155
- - Menganalisis ukuran bundle dan menyarankan peluang code splitting.
156
- - Meninjau kualitas kode (kompleksitas, duplikasi, kode mati).
157
- - Menggunakan tool berbantuan AI untuk mempercepat code review dan analisis.
158
-
159
- ### Protokol Analisis (5 Fase)
160
-
161
- #### Fase 1: Penemuan Arsitektur
162
- Petakan seluruh struktur proyek, hitung baris per file untuk menemukan file terbesar, dan deteksi dependensi circular dengan `npx madge --circular`.
163
-
164
- #### Fase 2: Analisis Bundle (Next.js / Vite)
165
- Gunakan `ANALYZE=true next build` atau `npx vite-bundle-visualizer`. Tanda bahaya bundle: chunk tunggal > 500KB, mengimpor library penuh, Moment.js, atau `node_modules` yang bocor ke bundle klien.
166
-
167
- #### Fase 3: Analisis Query Database
168
- Gunakan `pg_stat_statements` untuk menemukan query lambat. Cari scan sequential pada tabel besar (tanda indeks yang hilang). Aktifkan logging query di Drizzle/Prisma untuk mendeteksi pola N+1.
169
-
170
- #### Fase 4: Code Review Berbantuan AI
171
- Gunakan CodeRabbit untuk review PR otomatis, Sourcegraph Cody untuk pencarian semantik seluruh codebase, dan Gemini Agent dengan prompt analisis spesifik untuk menemukan fungsi panjang, logika bisnis yang diduplikasi, dan error handling yang hilang.
172
-
173
- #### Fase 5: Profiling Performa
174
- - **Frontend**: React DevTools Profiler, Lighthouse CI.
175
- - **Backend Node.js**: `node --prof`, Clinic.js untuk flamegraph.
176
- - **Go**: `go tool pprof` untuk CPU dan memory profiling.
177
-
178
- ### Pola Bottleneck Umum & Perbaikan
179
-
180
- | Bottleneck | Gejala | Perbaikan |
181
- |---|---|---|
182
- | Query N+1 | Panggilan DB proporsional dengan panjang daftar | Tambahkan `.include()` / JOIN atau DataLoader |
183
- | Indeks yang hilang | Query lambat pada kolom yang difilter | `CREATE INDEX CONCURRENTLY` |
184
- | Gambar tidak dioptimalkan | LCP besar, halaman lambat | Next.js `<Image>`, WebP, lazy loading |
185
- | Over-fetching | Mengambil objek penuh saat hanya 1 field dibutuhkan | Pilih kolom spesifik |
186
- | Tanpa paginasi | Mengambil seluruh tabel | Tambahkan `LIMIT/OFFSET` atau cursor pagination |
187
- | Memblokir thread utama | INP tinggi, UI tidak responsif | `useTransition`, web workers |
188
- | Tanpa caching | Data yang sama diambil berulang kali | Redis, React Query staleTime, HTTP cache |
189
- | Bundle membengkak | Payload JS besar | Tree-shaking, code splitting, lazy imports |
1
+ ---
2
+ name: app-analyzer-optimizer
3
+ description: "Deeply analyzes application architecture and structure to perform audit, bottleneck detection, and code/performance optimization / Mempelajari arsitektur dan struktur aplikasi secara mendalam untuk melakukan audit, deteksi bottleneck, serta optimasi performa dan kode."
4
+ author: vibes-plug-swarm
5
+ ---
6
+
7
+ # App Analyzer & Optimizer (2026 Edition)
8
+
9
+ [English](#english) | [Bahasa Indonesia](#bahasa-indonesia)
10
+
11
+ ---
12
+
13
+ <a name="english"></a>
14
+ ## English
15
+
16
+ ### Description
17
+ Deep application analysis and optimization skill. Performs architectural audits, bottleneck detection, bundle analysis, database query profiling, and AI-assisted code review across Next.js, React, Node.js, Go, Python, and Rust applications.
18
+
19
+ ### Trigger Conditions
20
+ - Auditing an existing codebase for architectural issues or technical debt.
21
+ - Detecting performance bottlenecks (slow API routes, large bundles, N+1 queries).
22
+ - Analyzing bundle size and suggesting code splitting opportunities.
23
+ - Reviewing code quality (complexity, duplication, dead code).
24
+ - Using AI-assisted tools to accelerate code review and analysis.
25
+
26
+ ### Analysis Protocol (5 Phases)
27
+
28
+ #### Phase 1: Architecture Discovery
29
+ ```bash
30
+ # Map the entire project structure
31
+ find . -type f -name "*.ts" -o -name "*.tsx" -o -name "*.go" | head -100
32
+ # Count lines per file (find largest files)
33
+ find . -name "*.ts" -exec wc -l {} + | sort -rn | head -20
34
+ # Find circular dependencies (TypeScript/JS)
35
+ npx madge --circular --extensions ts,tsx src/
36
+ ```
37
+
38
+ #### Phase 2: Bundle Analysis (Next.js / Vite)
39
+ ```bash
40
+ # Next.js bundle analyzer
41
+ ANALYZE=true next build
42
+
43
+ # Or install dedicated tool
44
+ npx @next/bundle-analyzer
45
+
46
+ # Vite bundle visualization
47
+ npx vite-bundle-visualizer
48
+
49
+ # Check for duplicate dependencies
50
+ npx depcheck
51
+ npx bundle-phobia-cli check package.json
52
+ ```
53
+
54
+ Key bundle red flags:
55
+ - Any single chunk > 500KB (uncompressed).
56
+ - Importing entire libraries (`import _ from 'lodash'` vs `import debounce from 'lodash/debounce'`).
57
+ - Moment.js (replace with `date-fns` or `Temporal`).
58
+ - `node_modules` leaking into client bundle.
59
+
60
+ #### Phase 3: Database Query Analysis
61
+ ```sql
62
+ -- PostgreSQL: Find slow queries
63
+ SELECT query, mean_exec_time, calls, total_exec_time
64
+ FROM pg_stat_statements
65
+ ORDER BY mean_exec_time DESC
66
+ LIMIT 20;
67
+
68
+ -- Find missing indexes (sequential scans on large tables)
69
+ SELECT schemaname, tablename, attname, n_distinct, correlation
70
+ FROM pg_stats
71
+ WHERE tablename = 'your_table'
72
+ ORDER BY n_distinct DESC;
73
+
74
+ -- Detect N+1 queries: Enable query logging
75
+ -- In Drizzle:
76
+ const db = drizzle(client, { logger: true });
77
+ -- In Prisma:
78
+ DATABASE_URL="...?connection_limit=5" prisma studio
79
+ ```
80
+
81
+ #### Phase 4: AI-Assisted Code Review
82
+ Use AI tools to accelerate analysis:
83
+
84
+ | Tool | Purpose |
85
+ |---|---|
86
+ | **CodeRabbit** | Automated PR review, pattern detection |
87
+ | **Sourcegraph Cody** | Codebase-wide semantic search and explanation |
88
+ | **GitHub Copilot** | Inline suggestions and refactoring |
89
+ | **Cursor / Windsurf** | AI IDE with full-repo context |
90
+
91
+ AI review prompts for Gemini Agent:
92
+ ```
93
+ Analyze all files in src/features/ and identify:
94
+ 1. Functions longer than 30 lines
95
+ 2. Duplicated business logic across files
96
+ 3. Missing error handling in async functions
97
+ 4. Components that directly call APIs (violating separation of concerns)
98
+ ```
99
+
100
+ #### Phase 5: Performance Profiling
101
+
102
+ **Frontend (React / Next.js):**
103
+ ```bash
104
+ # React DevTools Profiler — identify render bottlenecks
105
+ # Chrome DevTools > Performance tab > Record interaction
106
+
107
+ # Lighthouse CI — automated CWV tracking
108
+ npm install -g @lhci/cli
109
+ lhci autorun
110
+ ```
111
+
112
+ **Backend (Node.js):**
113
+ ```bash
114
+ # Built-in Node.js profiler
115
+ node --prof server.js
116
+ node --prof-process isolate-*.log > processed.txt
117
+
118
+ # Clinic.js — flamegraph, bubble chart, doctor
119
+ npm install -g clinic
120
+ clinic doctor -- node server.js
121
+ clinic flame -- node server.js
122
+ ```
123
+
124
+ **Go:**
125
+ ```bash
126
+ # Built-in pprof profiler
127
+ go tool pprof http://localhost:6060/debug/pprof/profile?seconds=30
128
+ go tool pprof -http=:8080 profile.out
129
+ ```
130
+
131
+ ### Common Bottleneck Patterns & Fixes
132
+
133
+ | Bottleneck | Symptom | Fix |
134
+ |---|---|---|
135
+ | N+1 queries | DB calls proportional to list length | Add `.include()` / JOIN or DataLoader |
136
+ | Missing indexes | Slow queries on filtered columns | `CREATE INDEX CONCURRENTLY` |
137
+ | Unoptimized images | Large LCP, slow page load | Next.js `<Image>`, WebP, lazy loading |
138
+ | Over-fetching | Fetching full objects when only 1 field needed | Select specific columns |
139
+ | No pagination | Fetching entire tables | Add `LIMIT/OFFSET` or cursor pagination |
140
+ | Blocking main thread | High INP, unresponsive UI | `useTransition`, web workers |
141
+ | No caching | Same data fetched repeatedly | Redis, React Query staleTime, HTTP cache |
142
+ | Bundle bloat | Large JS payload | Tree-shaking, code splitting, lazy imports |
143
+
144
+ ---
145
+
146
+ <a name="bahasa-indonesia"></a>
147
+ ## Bahasa Indonesia
148
+
149
+ ### Deskripsi
150
+ Skill analisis dan optimasi aplikasi mendalam. Melakukan audit arsitektur, deteksi bottleneck, analisis bundle, profiling query database, dan code review berbantuan AI di aplikasi Next.js, React, Node.js, Go, Python, dan Rust.
151
+
152
+ ### Kondisi Pemicu
153
+ - Mengaudit codebase yang ada untuk masalah arsitektur atau hutang teknis.
154
+ - Mendeteksi bottleneck performa (rute API lambat, bundle besar, query N+1).
155
+ - Menganalisis ukuran bundle dan menyarankan peluang code splitting.
156
+ - Meninjau kualitas kode (kompleksitas, duplikasi, kode mati).
157
+ - Menggunakan tool berbantuan AI untuk mempercepat code review dan analisis.
158
+
159
+ ### Protokol Analisis (5 Fase)
160
+
161
+ #### Fase 1: Penemuan Arsitektur
162
+ Petakan seluruh struktur proyek, hitung baris per file untuk menemukan file terbesar, dan deteksi dependensi circular dengan `npx madge --circular`.
163
+
164
+ #### Fase 2: Analisis Bundle (Next.js / Vite)
165
+ Gunakan `ANALYZE=true next build` atau `npx vite-bundle-visualizer`. Tanda bahaya bundle: chunk tunggal > 500KB, mengimpor library penuh, Moment.js, atau `node_modules` yang bocor ke bundle klien.
166
+
167
+ #### Fase 3: Analisis Query Database
168
+ Gunakan `pg_stat_statements` untuk menemukan query lambat. Cari scan sequential pada tabel besar (tanda indeks yang hilang). Aktifkan logging query di Drizzle/Prisma untuk mendeteksi pola N+1.
169
+
170
+ #### Fase 4: Code Review Berbantuan AI
171
+ Gunakan CodeRabbit untuk review PR otomatis, Sourcegraph Cody untuk pencarian semantik seluruh codebase, dan Gemini Agent dengan prompt analisis spesifik untuk menemukan fungsi panjang, logika bisnis yang diduplikasi, dan error handling yang hilang.
172
+
173
+ #### Fase 5: Profiling Performa
174
+ - **Frontend**: React DevTools Profiler, Lighthouse CI.
175
+ - **Backend Node.js**: `node --prof`, Clinic.js untuk flamegraph.
176
+ - **Go**: `go tool pprof` untuk CPU dan memory profiling.
177
+
178
+ ### Pola Bottleneck Umum & Perbaikan
179
+
180
+ | Bottleneck | Gejala | Perbaikan |
181
+ |---|---|---|
182
+ | Query N+1 | Panggilan DB proporsional dengan panjang daftar | Tambahkan `.include()` / JOIN atau DataLoader |
183
+ | Indeks yang hilang | Query lambat pada kolom yang difilter | `CREATE INDEX CONCURRENTLY` |
184
+ | Gambar tidak dioptimalkan | LCP besar, halaman lambat | Next.js `<Image>`, WebP, lazy loading |
185
+ | Over-fetching | Mengambil objek penuh saat hanya 1 field dibutuhkan | Pilih kolom spesifik |
186
+ | Tanpa paginasi | Mengambil seluruh tabel | Tambahkan `LIMIT/OFFSET` atau cursor pagination |
187
+ | Memblokir thread utama | INP tinggi, UI tidak responsif | `useTransition`, web workers |
188
+ | Tanpa caching | Data yang sama diambil berulang kali | Redis, React Query staleTime, HTTP cache |
189
+ | Bundle membengkak | Payload JS besar | Tree-shaking, code splitting, lazy imports |
190
+
191
+
192
+ ## Orchestration & Integration
193
+ - Integrates with performance-web-vitals and production-ready-hardener.
@@ -0,0 +1,142 @@
1
+ ---
2
+ name: apple-ecosystem-expert
3
+ description: "Expert guide for Apple Ecosystem development. Covers iOS support, Safari WebKit compatibility, PWAs (Progressive Web Apps) for iOS, and Human Interface Guidelines (HIG) for web and native apps / Panduan ahli pengembangan ekosistem Apple (iOS & Web)."
4
+ author: vibes-plug-swarm
5
+ ---
6
+
7
+ # Apple Ecosystem Expert — vibes-plug Skill
8
+
9
+ [English](#english) | [Bahasa Indonesia](#bahasa-indonesia)
10
+
11
+ ---
12
+
13
+ <a name="english"></a>
14
+ ## English
15
+
16
+ ### Description
17
+ Expert guide for Apple Ecosystem development. Covers Safari WebKit compatibility, Progressive Web Apps (PWAs) tailored for iOS, touch interactions, `manifest.json` configurations, and applying Human Interface Guidelines (HIG) principles to web and iOS applications.
18
+
19
+ ### Trigger Conditions
20
+ Activate this skill when the user is:
21
+ - Asking for Safari browser compatibility or fixing WebKit bugs.
22
+ - Developing PWAs or web apps targeting iOS/iPadOS devices.
23
+ - Asking about `apple-touch-icon`, `apple-mobile-web-app-capable`, or related meta tags.
24
+ - Building UI elements that need to look and feel native on Apple devices.
25
+
26
+ ---
27
+
28
+ ### Core Concepts
29
+
30
+ #### 1. iOS PWA & Meta Tags
31
+ To ensure a web application looks and acts like a native app on iOS when added to the home screen, include these specific meta tags and configurations:
32
+
33
+ ```html
34
+ <!-- iOS Safari PWA Meta Tags -->
35
+ <meta name="apple-mobile-web-app-capable" content="yes" />
36
+ <meta name="apple-mobile-web-app-status-bar-style" content="default" />
37
+ <meta name="apple-mobile-web-app-title" content="App Title" />
38
+ <link rel="apple-touch-icon" href="/icon-192x192.png" />
39
+ <!-- Support for splash screens requires specific sizes, consider using PWA asset generators -->
40
+ ```
41
+
42
+ #### 2. Safari WebKit CSS Quirks
43
+ Safari (WebKit) has distinct behavior for viewport sizing and scrolling.
44
+
45
+ | CSS Feature | WebKit Problem | Solution / Workaround |
46
+ |---|---|---|
47
+ | `100vh` | Ignores the bottom navigation bar on mobile Safari, causing overflow. | Use `100dvh` (Dynamic Viewport Height) or safe area insets. |
48
+ | Over-scrolling | "Rubber-banding" effect reveals background on scroll limits. | `overscroll-behavior: none;` on `body`. |
49
+ | Safe Area | Notches and Dynamic Islands block content. | Use `env(safe-area-inset-bottom)`, `env(safe-area-inset-top)`. |
50
+
51
+ ```css
52
+ /* Example: Handling safe area and dynamic viewport height */
53
+ .container {
54
+ height: 100dvh;
55
+ padding-top: env(safe-area-inset-top);
56
+ padding-bottom: env(safe-area-inset-bottom);
57
+ padding-left: env(safe-area-inset-left);
58
+ padding-right: env(safe-area-inset-right);
59
+ }
60
+ ```
61
+
62
+ #### 3. Touch and Interactions
63
+ To achieve native feel on iOS, touch interactions must be smooth. Use CSS properties like `-webkit-tap-highlight-color: transparent;` to remove the default grey tap highlight.
64
+
65
+ ---
66
+
67
+ ### Best Practices
68
+
69
+ 1. **Always use Dynamic Viewports (`dvh`, `svh`, `lvh`):** Standard `vh` in mobile Safari causes layout shifts or hidden content due to the dynamic browser UI.
70
+ 2. **Handle Safe Areas:** Utilize CSS `env()` variables to avoid content overlapping with the iOS notch or home indicator.
71
+ 3. **Optimized Touch Targets:** Apple HIG dictates a minimum touch target size of 44x44 pt. Ensure buttons are easily clickable.
72
+ 4. **PWA Icons and Manifest:** iOS does not fully respect standard `manifest.json` icons; you must provide `<link rel="apple-touch-icon">` explicitly.
73
+
74
+ ---
75
+
76
+ ### Common Pitfalls to Avoid
77
+
78
+ | Anti-Pattern | Problem | Correct Approach |
79
+ |---|---|---|
80
+ | Using `100vh` for full screen apps | Bottom content gets hidden under Safari's tab bar. | Use `100dvh`. |
81
+ | Ignoring `-webkit-appearance` | Buttons/inputs look like default iOS forms instead of custom UI. | Set `-webkit-appearance: none;` on form elements. |
82
+ | Relying only on `manifest.json` for PWA icons | iOS won't use them for the "Add to Home Screen" icon. | Include `<link rel="apple-touch-icon" href="...">`. |
83
+
84
+ ---
85
+
86
+ ### Integration with Other Skills (MANDATORY)
87
+
88
+ This skill works best when combined with:
89
+ - `hig` — For detailed implementation of Apple Human Interface Guidelines styling.
90
+ - `mobile-expo-expert` — When building React Native/Expo apps for iOS.
91
+ - `tailwind-expert` — To apply CSS adjustments like `dvh` and safe-areas using Tailwind utility classes.
92
+ - `ui-components-expert` — To ensure UI components are sized correctly for iOS touch targets (44x44).
93
+
94
+ ### Referenced By Orchestrators (MANDATORY)
95
+
96
+ This skill should be referenced by the following orchestrators:
97
+ - `brainstorming` — Add to the "Mobile & Web Ecosystems" row in the Skill Integration & Orchestration Matrix
98
+ - `zero-to-prod-orchestrator` — Add to Phase 4 (Frontend Implementation) & Phase 8 (Production Audit)
99
+ - `production-ready-hardener` — Add to Phase 2 (PWA & Compatibility Audit)
100
+
101
+ ---
102
+
103
+ <a name="bahasa-indonesia"></a>
104
+ ## Bahasa Indonesia
105
+
106
+ ### Deskripsi
107
+ Panduan ahli untuk pengembangan ekosistem Apple. Mencakup kompatibilitas Safari WebKit, Progressive Web Apps (PWA) khusus iOS, interaksi sentuhan, konfigurasi `manifest.json`, dan penerapan prinsip Human Interface Guidelines (HIG) untuk web dan aplikasi iOS.
108
+
109
+ ### Kondisi Pemicu
110
+ Aktifkan skill ini ketika pengguna sedang:
111
+ - Menanyakan kompatibilitas browser Safari atau memperbaiki bug WebKit.
112
+ - Mengembangkan PWA atau aplikasi web yang menargetkan perangkat iOS/iPadOS.
113
+ - Menanyakan tentang `apple-touch-icon`, meta tag PWA iOS, atau safe area.
114
+ - Membangun elemen UI agar terlihat dan terasa *native* di ekosistem Apple.
115
+
116
+ ### Panduan Singkat
117
+
118
+ Panduan praktis untuk dukungan Ekosistem Apple (iOS & Web):
119
+
120
+ - **[Gunakan `100dvh`]:** Jangan pernah gunakan `100vh` di web app iOS, gunakan `100dvh` (Dynamic Viewport Height) agar tidak tertutup navigation bar Safari.
121
+ - **[Meta Tag PWA Khusus]:** Wajib menggunakan `<link rel="apple-touch-icon">` dan `<meta name="apple-mobile-web-app-capable" content="yes">` agar PWA berjalan optimal saat ditambahkan ke Home Screen.
122
+ - **[Safe Area]:** Terapkan padding `env(safe-area-inset-top)` dsb, untuk menghindari notch (poni) dan Dynamic Island iPhone.
123
+ - **[Touch Targets HIG]:** Area sentuh minimum untuk elemen interaktif di iOS adalah 44x44 points.
124
+
125
+ ### Integrasi dengan Skill Lain (WAJIB)
126
+
127
+ Skill ini bekerja paling baik dikombinasikan dengan:
128
+ - `hig` — Untuk menerapkan struktur dan prinsip desain dari Human Interface Guidelines Apple.
129
+ - `mobile-expo-expert` — Jika menggunakan React Native untuk aplikasi iOS.
130
+ - `tailwind-expert` — Mengatur penyesuaian WebKit seperti `dvh` dan safe-areas dengan utility class.
131
+
132
+ ### Direferensikan oleh Orchestrator (WAJIB)
133
+
134
+ Skill ini harus direferensikan oleh orchestrator berikut:
135
+ - `brainstorming` — Bagian Mobile & Web Ecosystems.
136
+ - `zero-to-prod-orchestrator` — Fase 4 dan 8 (Kesiapan Produksi).
137
+ - `production-ready-hardener` — Fase 2 (Audit Kompatibilitas Lintas Browser & PWA).
138
+
139
+
140
+ ## Orchestration & Integration
141
+ - Integrates with: `hig`, `mobile-expo-expert`, `tailwind-expert`, `ui-components-expert`.
142
+ - Orchestrated by: `brainstorming`, `zero-to-prod-orchestrator`, `production-ready-hardener`.
@@ -0,0 +1,54 @@
1
+ ---
2
+ name: async-queue-temporal-expert
3
+ description: "Expert guide for Durable Workflow Engines (Temporal.io, Trigger.dev v3, Inngest, BullMQ v5) and fault-tolerant background sagas / Panduan ahli workflow engine tahan-gagal (Temporal, Trigger.dev, Inngest, BullMQ)."
4
+ author: vibes-plug-swarm
5
+ ---
6
+
7
+ # Async Queue & Durable Workflow Expert
8
+
9
+ [English](#english) | [Bahasa Indonesia](#bahasa-indonesia)
10
+
11
+ ---
12
+
13
+ <a name="english"></a>
14
+ ## English
15
+
16
+ ### Purpose & Overview
17
+ Production-grade guidance for designing durable, fault-tolerant background execution pipelines and distributed state machines using Temporal.io, Trigger.dev v3, Inngest, and BullMQ v5. Guarantees execution completion across long-running background tasks, API rate limits, and server crashes.
18
+
19
+ ### Key Capabilities
20
+ - **Durable Execution**: Automatic retry, state persistence, and resume after server restarts or network partitions.
21
+ - **Saga Pattern Orchestration**: Multi-step distributed transactions with compensation logic for rollback on failure.
22
+ - **Rate Limiting & Concurrency**: Controlled worker concurrency, backoff jitter, and per-tenant queue isolation.
23
+
24
+ ```typescript
25
+ import { task } from "@trigger.dev/sdk/v3";
26
+
27
+ export const generateSaaSReport = task({
28
+ id: "generate-saas-report",
29
+ run: async (payload: { tenantId: string }) => {
30
+ // Durable step execution with automatic retries
31
+ const data = await fetchTenantData(payload.tenantId);
32
+ const pdfUrl = await generatePDF(data);
33
+ await sendEmailReport(payload.tenantId, pdfUrl);
34
+ return { success: true, pdfUrl };
35
+ },
36
+ });
37
+ ```
38
+
39
+ ---
40
+
41
+ <a name="bahasa-indonesia"></a>
42
+ ## Bahasa Indonesia
43
+
44
+ ### Deskripsi
45
+ Panduan tingkat produksi untuk merancang pipeline eksekusi background yang tahan-gagal (durable execution) dan state machine terdistribusi menggunakan Temporal.io, Trigger.dev v3, Inngest, dan BullMQ v5. Menjamin penyelesaian eksekusi tugas background berdurasi panjang meskipun terjadi server crash atau pembatasan API rate limit.
46
+
47
+ ### Fitur Utama
48
+ - **Eksekusi Tahan-Gagal (Durable)**: Retry otomatis, persistensi state, dan kompensasi lanjutan setelah restart server.
49
+ - **Pola Saga**: Transaksi terdistribusi multi-langkah dengan logika kompensasi untuk pembatalan saat terjadi kegagalan.
50
+ - **Rate Limiting & Konkurensi**: Kontrol konkurensi worker, backoff jitter, dan isolasi antrean per-tenant.
51
+
52
+
53
+ ## Orchestration & Integration
54
+ - Connects to other backend skills as part of the orchestration flow.