proagents 1.6.16 → 1.6.18
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.
- package/.claude/settings.local.json +169 -0
- package/COMMANDS.md +595 -0
- package/README.md +22 -64
- package/bin/proagents.js +0 -2
- package/lib/commands/init.js +4 -174
- package/package.json +2 -7
- package/.proagents/ai-models/README.md +0 -141
- package/.proagents/ai-models/cost-management.md +0 -362
- package/.proagents/ai-models/fallbacks.md +0 -342
- package/.proagents/ai-models/model-config.md +0 -318
- package/.proagents/ai-models/task-routing.md +0 -503
- package/.proagents/ai-training/README.md +0 -155
- package/.proagents/ai-training/continuous-learning.md +0 -413
- package/.proagents/ai-training/domain-knowledge.md +0 -378
- package/.proagents/ai-training/pattern-learning.md +0 -455
- package/.proagents/ai-training/training-data.md +0 -337
- package/.proagents/ai-training/user-preferences.md +0 -346
- package/.proagents/approval-workflows/README.md +0 -146
- package/.proagents/approval-workflows/approval-config.md +0 -332
- package/.proagents/approval-workflows/approval-stages.md +0 -503
- package/.proagents/approval-workflows/emergency-bypass.md +0 -351
- package/.proagents/approval-workflows/examples.md +0 -859
- package/.proagents/approval-workflows/notifications.md +0 -320
- package/.proagents/compliance/README.md +0 -206
- package/.proagents/compliance/access-control.md +0 -310
- package/.proagents/compliance/audit-logging.md +0 -444
- package/.proagents/compliance/compliance-frameworks.md +0 -429
- package/.proagents/compliance/reports.md +0 -491
- package/.proagents/compliance/retention-policies.md +0 -454
- package/.proagents/config-versioning/README.md +0 -120
- package/.proagents/config-versioning/changelog.md +0 -300
- package/.proagents/config-versioning/rollback.md +0 -283
- package/.proagents/config-versioning/versioning.md +0 -330
- package/.proagents/contract-testing/README.md +0 -223
- package/.proagents/contract-testing/contract-testing.md +0 -614
- package/.proagents/contract-testing/pact-integration.md +0 -507
- package/.proagents/contract-testing/schema-validation.md +0 -565
- package/.proagents/dependency-management/README.md +0 -140
- package/.proagents/dependency-management/automation.md +0 -363
- package/.proagents/dependency-management/compatibility.md +0 -319
- package/.proagents/dependency-management/security-scanning.md +0 -413
- package/.proagents/dependency-management/update-policies.md +0 -374
- package/.proagents/disaster-recovery/README.md +0 -247
- package/.proagents/disaster-recovery/automation.md +0 -366
- package/.proagents/disaster-recovery/backup-recovery.md +0 -571
- package/.proagents/disaster-recovery/incident-response.md +0 -565
- package/.proagents/disaster-recovery/rollback-procedures.md +0 -499
- package/.proagents/disaster-recovery/runbooks.md +0 -603
- package/.proagents/disaster-recovery/scenarios.md +0 -892
- package/.proagents/disaster-recovery/testing.md +0 -438
- package/.proagents/environments/README.md +0 -244
- package/.proagents/environments/configuration.md +0 -437
- package/.proagents/environments/promotion.md +0 -434
- package/.proagents/environments/setup.md +0 -420
- package/.proagents/examples/README.md +0 -55
- package/.proagents/examples/backend-nodejs/README.md +0 -188
- package/.proagents/examples/backend-nodejs/complete-conversation.md +0 -601
- package/.proagents/examples/backend-nodejs/proagents.config.yaml +0 -415
- package/.proagents/examples/backend-nodejs/workflow-example.md +0 -909
- package/.proagents/examples/fullstack-nextjs/README.md +0 -155
- package/.proagents/examples/fullstack-nextjs/complete-conversation.md +0 -604
- package/.proagents/examples/fullstack-nextjs/proagents.config.yaml +0 -287
- package/.proagents/examples/fullstack-nextjs/workflow-example.md +0 -553
- package/.proagents/examples/mobile-react-native/README.md +0 -171
- package/.proagents/examples/mobile-react-native/complete-conversation.md +0 -825
- package/.proagents/examples/mobile-react-native/proagents.config.yaml +0 -330
- package/.proagents/examples/mobile-react-native/workflow-example.md +0 -723
- package/.proagents/examples/web-frontend-react/README.md +0 -125
- package/.proagents/examples/web-frontend-react/complete-conversation.md +0 -556
- package/.proagents/examples/web-frontend-react/proagents.config.yaml +0 -183
- package/.proagents/examples/web-frontend-react/workflow-example.md +0 -603
- package/.proagents/existing-projects/README.md +0 -65
- package/.proagents/existing-projects/challenges.md +0 -861
- package/.proagents/existing-projects/coexistence-mode.md +0 -483
- package/.proagents/existing-projects/compatibility-assessment.md +0 -541
- package/.proagents/existing-projects/gradual-adoption.md +0 -515
- package/.proagents/existing-projects/migration-strategies.md +0 -788
- package/.proagents/existing-projects/pattern-reconciliation.md +0 -489
- package/.proagents/existing-projects/team-onboarding.md +0 -617
- package/.proagents/existing-projects/technical-debt-handling.md +0 -644
- package/.proagents/feature-flags/README.md +0 -263
- package/.proagents/feature-flags/ab-testing.md +0 -413
- package/.proagents/feature-flags/configuration.md +0 -420
- package/.proagents/feature-flags/kill-switches.md +0 -444
- package/.proagents/feature-flags/rollout-strategies.md +0 -392
- package/.proagents/history.log +0 -12
- package/.proagents/i18n/README.md +0 -133
- package/.proagents/i18n/extraction.md +0 -433
- package/.proagents/i18n/tms-integration.md +0 -332
- package/.proagents/i18n/translation-workflow.md +0 -413
- package/.proagents/i18n/validation.md +0 -355
- package/.proagents/logging/README.md +0 -276
- package/.proagents/logging/aggregation.md +0 -475
- package/.proagents/logging/log-levels.md +0 -376
- package/.proagents/logging/sensitive-data.md +0 -423
- package/.proagents/logging/structured-logging.md +0 -406
- package/.proagents/metrics/README.md +0 -69
- package/.proagents/metrics/code-quality-kpis.md +0 -461
- package/.proagents/metrics/deployment-metrics.md +0 -517
- package/.proagents/metrics/developer-productivity.md +0 -368
- package/.proagents/metrics/learning-effectiveness.md +0 -478
- package/.proagents/migrations/README.md +0 -77
- package/.proagents/migrations/from-claude-projects.md +0 -313
- package/.proagents/migrations/from-cursor-rules.md +0 -345
- package/.proagents/migrations/from-custom-workflows.md +0 -410
- package/.proagents/monitoring/README.md +0 -308
- package/.proagents/monitoring/alerting.md +0 -449
- package/.proagents/monitoring/dashboards.md +0 -454
- package/.proagents/monitoring/health-checks.md +0 -436
- package/.proagents/monitoring/metrics.md +0 -434
- package/.proagents/multi-project/README.md +0 -170
- package/.proagents/multi-project/coordinated-deploy.md +0 -510
- package/.proagents/multi-project/cross-project-deps.md +0 -395
- package/.proagents/multi-project/unified-changelog.md +0 -477
- package/.proagents/multi-project/walkthroughs/monorepo-setup.md +0 -787
- package/.proagents/multi-project/workspace-config.md +0 -408
- package/.proagents/notifications/README.md +0 -151
- package/.proagents/notifications/channels.md +0 -457
- package/.proagents/notifications/preferences.md +0 -415
- package/.proagents/notifications/routing.md +0 -449
- package/.proagents/notifications/scheduling.md +0 -425
- package/.proagents/notifications/templates.md +0 -446
- package/.proagents/offline-mode/README.md +0 -145
- package/.proagents/offline-mode/caching.md +0 -344
- package/.proagents/offline-mode/offline-operations.md +0 -312
- package/.proagents/offline-mode/queue-specifications.md +0 -679
- package/.proagents/offline-mode/sync.md +0 -475
- package/.proagents/parallel-features/README.md +0 -85
- package/.proagents/parallel-features/conflict-detection.md +0 -226
- package/.proagents/parallel-features/dependency-management.md +0 -392
- package/.proagents/parallel-features/merge-coordination.md +0 -506
- package/.proagents/parallel-features/tracking-system.md +0 -416
- package/.proagents/performance/README.md +0 -59
- package/.proagents/performance/bundle-analysis.md +0 -375
- package/.proagents/performance/load-testing.md +0 -563
- package/.proagents/performance/runtime-metrics.md +0 -489
- package/.proagents/performance/web-vitals.md +0 -425
- package/.proagents/plugins/README.md +0 -139
- package/.proagents/plugins/creating-plugins.md +0 -504
- package/.proagents/plugins/plugin-api.md +0 -467
- package/.proagents/plugins/plugin-registry.md +0 -276
- package/.proagents/reporting/README.md +0 -158
- package/.proagents/reporting/dashboards.md +0 -366
- package/.proagents/reporting/exports.md +0 -524
- package/.proagents/reporting/quality-metrics.md +0 -385
- package/.proagents/reporting/templates/README.md +0 -56
- package/.proagents/reporting/templates/dashboard-config.json +0 -187
- package/.proagents/reporting/templates/metrics-queries.md +0 -427
- package/.proagents/reporting/templates/react-dashboard.tsx +0 -544
- package/.proagents/reporting/templates/widgets.md +0 -451
- package/.proagents/reporting/velocity-metrics.md +0 -340
- package/.proagents/reverse-engineering/README.md +0 -151
- package/.proagents/reverse-engineering/architecture-extraction.md +0 -325
- package/.proagents/reverse-engineering/code-analysis.md +0 -377
- package/.proagents/reverse-engineering/dependency-mapping.md +0 -567
- package/.proagents/reverse-engineering/diagram-generation.md +0 -586
- package/.proagents/reverse-engineering/documentation-generation.md +0 -468
- package/.proagents/reverse-engineering/pattern-detection.md +0 -569
- package/.proagents/reverse-engineering/quality-assessment.md +0 -733
- package/.proagents/secrets/README.md +0 -278
- package/.proagents/secrets/access-control.md +0 -443
- package/.proagents/secrets/rotation.md +0 -403
- package/.proagents/secrets/scanning.md +0 -487
- package/.proagents/secrets/storage.md +0 -394
- package/.proagents/webhooks/README.md +0 -126
- package/.proagents/webhooks/endpoints.md +0 -298
- package/.proagents/webhooks/events.md +0 -316
- package/.proagents/webhooks/payloads.md +0 -325
- package/.proagents/webhooks/reliability.md +0 -363
- package/.proagents/webhooks/security.md +0 -380
|
@@ -1,567 +0,0 @@
|
|
|
1
|
-
# Dependency Mapping
|
|
2
|
-
|
|
3
|
-
Map and visualize all dependencies in a codebase - internal modules, external packages, and their relationships.
|
|
4
|
-
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
## Overview
|
|
8
|
-
|
|
9
|
-
Dependency mapping provides:
|
|
10
|
-
- Clear understanding of code relationships
|
|
11
|
-
- Impact analysis for changes
|
|
12
|
-
- Circular dependency detection
|
|
13
|
-
- Dead code identification
|
|
14
|
-
- Upgrade planning for packages
|
|
15
|
-
|
|
16
|
-
---
|
|
17
|
-
|
|
18
|
-
## Mapping Types
|
|
19
|
-
|
|
20
|
-
### 1. Internal Module Dependencies
|
|
21
|
-
|
|
22
|
-
```yaml
|
|
23
|
-
internal_dependencies:
|
|
24
|
-
module: "src/features/auth"
|
|
25
|
-
|
|
26
|
-
imports_from:
|
|
27
|
-
internal:
|
|
28
|
-
- module: "src/lib/api"
|
|
29
|
-
imports: ["api", "ApiError"]
|
|
30
|
-
usage: "API calls"
|
|
31
|
-
|
|
32
|
-
- module: "src/stores/authStore"
|
|
33
|
-
imports: ["useAuthStore"]
|
|
34
|
-
usage: "State management"
|
|
35
|
-
|
|
36
|
-
- module: "src/types/auth"
|
|
37
|
-
imports: ["User", "AuthResponse", "LoginInput"]
|
|
38
|
-
usage: "Type definitions"
|
|
39
|
-
|
|
40
|
-
shared:
|
|
41
|
-
- module: "src/components/ui"
|
|
42
|
-
imports: ["Button", "Input", "Card"]
|
|
43
|
-
usage: "UI components"
|
|
44
|
-
|
|
45
|
-
- module: "src/hooks/useToast"
|
|
46
|
-
imports: ["useToast"]
|
|
47
|
-
usage: "Notifications"
|
|
48
|
-
|
|
49
|
-
exported_to:
|
|
50
|
-
- module: "src/pages/login"
|
|
51
|
-
exports: ["LoginForm", "useAuth"]
|
|
52
|
-
|
|
53
|
-
- module: "src/features/dashboard"
|
|
54
|
-
exports: ["useAuth", "AuthProvider"]
|
|
55
|
-
|
|
56
|
-
- module: "src/app/layout"
|
|
57
|
-
exports: ["AuthProvider"]
|
|
58
|
-
```
|
|
59
|
-
|
|
60
|
-
**Dependency Graph:**
|
|
61
|
-
```
|
|
62
|
-
┌─────────────────────────────────────────────────────────────┐
|
|
63
|
-
│ auth module │
|
|
64
|
-
├─────────────────────────────────────────────────────────────┤
|
|
65
|
-
│ │
|
|
66
|
-
│ Imports From: Exports To: │
|
|
67
|
-
│ ───────────── ─────────── │
|
|
68
|
-
│ ┌─────────┐ ┌─────────┐ │
|
|
69
|
-
│ │ api │──────┐ ┌─────────▶│ login │ │
|
|
70
|
-
│ └─────────┘ │ │ │ page │ │
|
|
71
|
-
│ │ │ └─────────┘ │
|
|
72
|
-
│ ┌─────────┐ │ │ │
|
|
73
|
-
│ │authStore│──────┼────┼─────────▶┌─────────┐ │
|
|
74
|
-
│ └─────────┘ │ │ │dashboard│ │
|
|
75
|
-
│ ▼ │ └─────────┘ │
|
|
76
|
-
│ ┌─────────┐ ┌──────────┐ │
|
|
77
|
-
│ │ types │──▶│ AUTH │──────▶┌─────────┐ │
|
|
78
|
-
│ └─────────┘ │ MODULE │ │ layout │ │
|
|
79
|
-
│ └──────────┘ └─────────┘ │
|
|
80
|
-
│ ┌─────────┐ ▲ │
|
|
81
|
-
│ │ ui │──────┤ │
|
|
82
|
-
│ └─────────┘ │ │
|
|
83
|
-
│ │ │
|
|
84
|
-
│ ┌─────────┐ │ │
|
|
85
|
-
│ │useToast │──────┘ │
|
|
86
|
-
│ └─────────┘ │
|
|
87
|
-
│ │
|
|
88
|
-
└─────────────────────────────────────────────────────────────┘
|
|
89
|
-
```
|
|
90
|
-
|
|
91
|
-
---
|
|
92
|
-
|
|
93
|
-
### 2. External Package Dependencies
|
|
94
|
-
|
|
95
|
-
```yaml
|
|
96
|
-
external_dependencies:
|
|
97
|
-
production:
|
|
98
|
-
core:
|
|
99
|
-
- name: "react"
|
|
100
|
-
version: "18.2.0"
|
|
101
|
-
imported_by: 128 files
|
|
102
|
-
usage: "Core framework"
|
|
103
|
-
|
|
104
|
-
- name: "next"
|
|
105
|
-
version: "14.0.0"
|
|
106
|
-
imported_by: 45 files
|
|
107
|
-
usage: "Framework"
|
|
108
|
-
|
|
109
|
-
state:
|
|
110
|
-
- name: "zustand"
|
|
111
|
-
version: "4.4.0"
|
|
112
|
-
imported_by: 12 files
|
|
113
|
-
usage: "Global state"
|
|
114
|
-
|
|
115
|
-
- name: "@tanstack/react-query"
|
|
116
|
-
version: "5.0.0"
|
|
117
|
-
imported_by: 34 files
|
|
118
|
-
usage: "Server state"
|
|
119
|
-
|
|
120
|
-
ui:
|
|
121
|
-
- name: "tailwindcss"
|
|
122
|
-
version: "3.4.0"
|
|
123
|
-
imported_by: "CSS config"
|
|
124
|
-
usage: "Styling"
|
|
125
|
-
|
|
126
|
-
- name: "class-variance-authority"
|
|
127
|
-
version: "0.7.0"
|
|
128
|
-
imported_by: 25 files
|
|
129
|
-
usage: "Component variants"
|
|
130
|
-
|
|
131
|
-
utilities:
|
|
132
|
-
- name: "date-fns"
|
|
133
|
-
version: "3.0.0"
|
|
134
|
-
imported_by: 15 files
|
|
135
|
-
functions_used: ["format", "parseISO", "isAfter"]
|
|
136
|
-
|
|
137
|
-
- name: "lodash-es"
|
|
138
|
-
version: "4.17.21"
|
|
139
|
-
imported_by: 8 files
|
|
140
|
-
functions_used: ["debounce", "throttle", "groupBy"]
|
|
141
|
-
|
|
142
|
-
development:
|
|
143
|
-
- name: "typescript"
|
|
144
|
-
version: "5.3.0"
|
|
145
|
-
|
|
146
|
-
- name: "vitest"
|
|
147
|
-
version: "1.0.0"
|
|
148
|
-
|
|
149
|
-
- name: "eslint"
|
|
150
|
-
version: "8.56.0"
|
|
151
|
-
|
|
152
|
-
- name: "@types/node"
|
|
153
|
-
version: "20.10.0"
|
|
154
|
-
```
|
|
155
|
-
|
|
156
|
-
---
|
|
157
|
-
|
|
158
|
-
### 3. Dependency Tree
|
|
159
|
-
|
|
160
|
-
```yaml
|
|
161
|
-
dependency_tree:
|
|
162
|
-
react:
|
|
163
|
-
version: "18.2.0"
|
|
164
|
-
dependencies:
|
|
165
|
-
- "loose-envify@1.4.0"
|
|
166
|
-
- "scheduler@0.23.0"
|
|
167
|
-
|
|
168
|
-
next:
|
|
169
|
-
version: "14.0.0"
|
|
170
|
-
dependencies:
|
|
171
|
-
- "react@18.2.0" (peer)
|
|
172
|
-
- "react-dom@18.2.0" (peer)
|
|
173
|
-
- "@next/env@14.0.0"
|
|
174
|
-
- "@swc/helpers@0.5.0"
|
|
175
|
-
- "postcss@8.4.31"
|
|
176
|
-
# ... more
|
|
177
|
-
|
|
178
|
-
"@tanstack/react-query":
|
|
179
|
-
version: "5.0.0"
|
|
180
|
-
dependencies:
|
|
181
|
-
- "@tanstack/query-core@5.0.0"
|
|
182
|
-
- "react@18.2.0" (peer)
|
|
183
|
-
|
|
184
|
-
total_packages: 856
|
|
185
|
-
direct_dependencies: 45
|
|
186
|
-
transitive_dependencies: 811
|
|
187
|
-
```
|
|
188
|
-
|
|
189
|
-
---
|
|
190
|
-
|
|
191
|
-
### 4. Import Analysis
|
|
192
|
-
|
|
193
|
-
```yaml
|
|
194
|
-
import_analysis:
|
|
195
|
-
most_imported_internal:
|
|
196
|
-
- module: "@/lib/utils"
|
|
197
|
-
imports: 89
|
|
198
|
-
exports_used: ["cn", "formatDate", "generateId"]
|
|
199
|
-
|
|
200
|
-
- module: "@/components/ui/button"
|
|
201
|
-
imports: 67
|
|
202
|
-
exports_used: ["Button", "buttonVariants"]
|
|
203
|
-
|
|
204
|
-
- module: "@/hooks/useAuth"
|
|
205
|
-
imports: 45
|
|
206
|
-
exports_used: ["useAuth", "AuthProvider"]
|
|
207
|
-
|
|
208
|
-
- module: "@/types"
|
|
209
|
-
imports: 42
|
|
210
|
-
exports_used: ["User", "Post", "ApiResponse"]
|
|
211
|
-
|
|
212
|
-
most_imported_external:
|
|
213
|
-
- package: "react"
|
|
214
|
-
imports: 128
|
|
215
|
-
exports_used: ["useState", "useEffect", "useCallback", "memo"]
|
|
216
|
-
|
|
217
|
-
- package: "next/navigation"
|
|
218
|
-
imports: 34
|
|
219
|
-
exports_used: ["useRouter", "useSearchParams", "redirect"]
|
|
220
|
-
|
|
221
|
-
- package: "@tanstack/react-query"
|
|
222
|
-
imports: 34
|
|
223
|
-
exports_used: ["useQuery", "useMutation", "QueryClient"]
|
|
224
|
-
|
|
225
|
-
import_patterns:
|
|
226
|
-
barrel_exports: true
|
|
227
|
-
path_aliases: ["@/*"]
|
|
228
|
-
absolute_imports: true
|
|
229
|
-
```
|
|
230
|
-
|
|
231
|
-
---
|
|
232
|
-
|
|
233
|
-
### 5. Circular Dependency Detection
|
|
234
|
-
|
|
235
|
-
```yaml
|
|
236
|
-
circular_dependencies:
|
|
237
|
-
found: 3
|
|
238
|
-
severity: "warning"
|
|
239
|
-
|
|
240
|
-
cycles:
|
|
241
|
-
- cycle: 1
|
|
242
|
-
severity: "high"
|
|
243
|
-
path:
|
|
244
|
-
- "src/features/auth/hooks/useAuth.ts"
|
|
245
|
-
- "src/features/user/services/userService.ts"
|
|
246
|
-
- "src/features/auth/services/authService.ts"
|
|
247
|
-
- "src/features/auth/hooks/useAuth.ts"
|
|
248
|
-
resolution: |
|
|
249
|
-
Extract shared types to src/types/auth.ts
|
|
250
|
-
Use dependency injection in services
|
|
251
|
-
|
|
252
|
-
- cycle: 2
|
|
253
|
-
severity: "medium"
|
|
254
|
-
path:
|
|
255
|
-
- "src/components/Modal.tsx"
|
|
256
|
-
- "src/components/Form.tsx"
|
|
257
|
-
- "src/components/Modal.tsx"
|
|
258
|
-
resolution: |
|
|
259
|
-
Create separate ModalForm component
|
|
260
|
-
Or pass Form as children to Modal
|
|
261
|
-
|
|
262
|
-
- cycle: 3
|
|
263
|
-
severity: "low"
|
|
264
|
-
path:
|
|
265
|
-
- "src/utils/format.ts"
|
|
266
|
-
- "src/utils/validate.ts"
|
|
267
|
-
- "src/utils/format.ts"
|
|
268
|
-
resolution: |
|
|
269
|
-
Move shared helpers to src/utils/helpers.ts
|
|
270
|
-
```
|
|
271
|
-
|
|
272
|
-
**Visualization:**
|
|
273
|
-
```mermaid
|
|
274
|
-
graph LR
|
|
275
|
-
subgraph Cycle1[Circular Dependency]
|
|
276
|
-
useAuth --> userService
|
|
277
|
-
userService --> authService
|
|
278
|
-
authService --> useAuth
|
|
279
|
-
end
|
|
280
|
-
|
|
281
|
-
style useAuth fill:#ff6b6b
|
|
282
|
-
style userService fill:#ff6b6b
|
|
283
|
-
style authService fill:#ff6b6b
|
|
284
|
-
```
|
|
285
|
-
|
|
286
|
-
---
|
|
287
|
-
|
|
288
|
-
### 6. Dead Code Detection
|
|
289
|
-
|
|
290
|
-
```yaml
|
|
291
|
-
dead_code:
|
|
292
|
-
unused_exports:
|
|
293
|
-
- file: "src/utils/legacy.ts"
|
|
294
|
-
exports:
|
|
295
|
-
- "formatCurrency" # Never imported
|
|
296
|
-
- "parseDateOld" # Never imported
|
|
297
|
-
recommendation: "Remove or mark as deprecated"
|
|
298
|
-
|
|
299
|
-
- file: "src/components/OldButton.tsx"
|
|
300
|
-
exports:
|
|
301
|
-
- "OldButton"
|
|
302
|
-
recommendation: "Remove - replaced by new Button"
|
|
303
|
-
|
|
304
|
-
unused_files:
|
|
305
|
-
- "src/utils/deprecated.ts"
|
|
306
|
-
- "src/components/legacy/Card.tsx"
|
|
307
|
-
- "src/hooks/useOldAuth.ts"
|
|
308
|
-
|
|
309
|
-
unused_dependencies:
|
|
310
|
-
- package: "moment"
|
|
311
|
-
installed: true
|
|
312
|
-
imported: false
|
|
313
|
-
recommendation: "Remove from package.json"
|
|
314
|
-
|
|
315
|
-
- package: "lodash"
|
|
316
|
-
installed: true
|
|
317
|
-
imported: false
|
|
318
|
-
note: "lodash-es is used instead"
|
|
319
|
-
|
|
320
|
-
potentially_dead:
|
|
321
|
-
- file: "src/services/analyticsService.ts"
|
|
322
|
-
reason: "Only imported in commented-out code"
|
|
323
|
-
confidence: 0.85
|
|
324
|
-
```
|
|
325
|
-
|
|
326
|
-
---
|
|
327
|
-
|
|
328
|
-
### 7. Impact Analysis
|
|
329
|
-
|
|
330
|
-
```yaml
|
|
331
|
-
impact_analysis:
|
|
332
|
-
file: "src/lib/api.ts"
|
|
333
|
-
|
|
334
|
-
direct_dependents: 24
|
|
335
|
-
indirect_dependents: 86
|
|
336
|
-
total_affected: 110
|
|
337
|
-
|
|
338
|
-
dependents_by_type:
|
|
339
|
-
services: 18
|
|
340
|
-
hooks: 12
|
|
341
|
-
components: 56
|
|
342
|
-
pages: 24
|
|
343
|
-
|
|
344
|
-
breaking_change_impact:
|
|
345
|
-
if_removed:
|
|
346
|
-
- "All API calls will fail"
|
|
347
|
-
- "86 components affected"
|
|
348
|
-
- "Critical severity"
|
|
349
|
-
|
|
350
|
-
if_signature_changed:
|
|
351
|
-
files_to_update: 24
|
|
352
|
-
estimated_effort: "2-4 hours"
|
|
353
|
-
|
|
354
|
-
dependency_chain:
|
|
355
|
-
api.ts:
|
|
356
|
-
- authService.ts:
|
|
357
|
-
- useAuth.ts:
|
|
358
|
-
- LoginPage.tsx
|
|
359
|
-
- DashboardLayout.tsx
|
|
360
|
-
- ProtectedRoute.tsx
|
|
361
|
-
- AuthProvider.tsx:
|
|
362
|
-
- App.tsx
|
|
363
|
-
- userService.ts:
|
|
364
|
-
- useUser.ts:
|
|
365
|
-
- ProfilePage.tsx
|
|
366
|
-
- SettingsPage.tsx
|
|
367
|
-
```
|
|
368
|
-
|
|
369
|
-
---
|
|
370
|
-
|
|
371
|
-
### 8. Package Health Analysis
|
|
372
|
-
|
|
373
|
-
```yaml
|
|
374
|
-
package_health:
|
|
375
|
-
outdated:
|
|
376
|
-
- package: "axios"
|
|
377
|
-
current: "1.3.0"
|
|
378
|
-
latest: "1.6.0"
|
|
379
|
-
update_type: "minor"
|
|
380
|
-
breaking_changes: false
|
|
381
|
-
|
|
382
|
-
- package: "react-hook-form"
|
|
383
|
-
current: "7.40.0"
|
|
384
|
-
latest: "7.48.0"
|
|
385
|
-
update_type: "minor"
|
|
386
|
-
breaking_changes: false
|
|
387
|
-
|
|
388
|
-
- package: "zod"
|
|
389
|
-
current: "3.20.0"
|
|
390
|
-
latest: "3.22.0"
|
|
391
|
-
update_type: "minor"
|
|
392
|
-
breaking_changes: false
|
|
393
|
-
|
|
394
|
-
security_vulnerabilities:
|
|
395
|
-
critical: 0
|
|
396
|
-
high: 0
|
|
397
|
-
moderate: 1
|
|
398
|
-
low: 2
|
|
399
|
-
details:
|
|
400
|
-
- package: "semver"
|
|
401
|
-
severity: "moderate"
|
|
402
|
-
vulnerability: "ReDoS"
|
|
403
|
-
fix: "Upgrade to 7.5.4"
|
|
404
|
-
path: "npm > semver"
|
|
405
|
-
|
|
406
|
-
deprecated:
|
|
407
|
-
- package: "request"
|
|
408
|
-
alternative: "Use axios or fetch"
|
|
409
|
-
used_by: "Old migration script"
|
|
410
|
-
|
|
411
|
-
license_issues:
|
|
412
|
-
- package: "gpl-package"
|
|
413
|
-
license: "GPL-3.0"
|
|
414
|
-
issue: "Incompatible with MIT"
|
|
415
|
-
action: "Review usage"
|
|
416
|
-
```
|
|
417
|
-
|
|
418
|
-
---
|
|
419
|
-
|
|
420
|
-
## Dependency Report
|
|
421
|
-
|
|
422
|
-
```markdown
|
|
423
|
-
# Dependency Analysis Report
|
|
424
|
-
|
|
425
|
-
## Project: MyApp
|
|
426
|
-
## Analyzed: 2024-01-15
|
|
427
|
-
|
|
428
|
-
---
|
|
429
|
-
|
|
430
|
-
## Summary
|
|
431
|
-
|
|
432
|
-
| Category | Count |
|
|
433
|
-
|----------|-------|
|
|
434
|
-
| Direct Dependencies | 45 |
|
|
435
|
-
| Dev Dependencies | 28 |
|
|
436
|
-
| Total Packages | 856 |
|
|
437
|
-
| Internal Modules | 34 |
|
|
438
|
-
| Circular Dependencies | 3 |
|
|
439
|
-
| Unused Packages | 2 |
|
|
440
|
-
| Security Issues | 1 |
|
|
441
|
-
|
|
442
|
-
---
|
|
443
|
-
|
|
444
|
-
## Internal Module Map
|
|
445
|
-
|
|
446
|
-
### Most Coupled Modules
|
|
447
|
-
| Module | Imports | Exports To | Coupling Score |
|
|
448
|
-
|--------|---------|------------|----------------|
|
|
449
|
-
| @/lib/api | 5 | 24 | High |
|
|
450
|
-
| @/hooks/useAuth | 8 | 45 | High |
|
|
451
|
-
| @/components/ui | 2 | 67 | Medium |
|
|
452
|
-
| @/types | 0 | 42 | Low (Good) |
|
|
453
|
-
|
|
454
|
-
### Module Boundaries
|
|
455
|
-
- Well-defined: auth, dashboard, settings
|
|
456
|
-
- Needs work: utils (too many responsibilities)
|
|
457
|
-
- Good isolation: types, constants
|
|
458
|
-
|
|
459
|
-
---
|
|
460
|
-
|
|
461
|
-
## External Package Analysis
|
|
462
|
-
|
|
463
|
-
### Critical Dependencies
|
|
464
|
-
| Package | Imported By | Risk if Removed |
|
|
465
|
-
|---------|-------------|-----------------|
|
|
466
|
-
| react | 128 files | Total failure |
|
|
467
|
-
| next | 45 files | Total failure |
|
|
468
|
-
| zustand | 12 files | State management failure |
|
|
469
|
-
| axios | 24 files | API failure |
|
|
470
|
-
|
|
471
|
-
### Bundle Size Impact
|
|
472
|
-
| Package | Size | Tree-shakeable |
|
|
473
|
-
|---------|------|----------------|
|
|
474
|
-
| lodash-es | 25KB | Yes |
|
|
475
|
-
| date-fns | 18KB | Yes |
|
|
476
|
-
| axios | 14KB | No |
|
|
477
|
-
| zod | 12KB | Yes |
|
|
478
|
-
|
|
479
|
-
---
|
|
480
|
-
|
|
481
|
-
## Issues Found
|
|
482
|
-
|
|
483
|
-
### Critical
|
|
484
|
-
- None
|
|
485
|
-
|
|
486
|
-
### Warning
|
|
487
|
-
1. 3 circular dependencies detected
|
|
488
|
-
2. 1 moderate security vulnerability (semver)
|
|
489
|
-
|
|
490
|
-
### Info
|
|
491
|
-
1. 2 unused packages can be removed
|
|
492
|
-
2. 5 packages have updates available
|
|
493
|
-
|
|
494
|
-
---
|
|
495
|
-
|
|
496
|
-
## Recommendations
|
|
497
|
-
|
|
498
|
-
1. **Remove unused packages:**
|
|
499
|
-
```bash
|
|
500
|
-
npm uninstall moment lodash
|
|
501
|
-
```
|
|
502
|
-
|
|
503
|
-
2. **Fix circular dependencies:**
|
|
504
|
-
- See circular_dependencies section for resolution
|
|
505
|
-
|
|
506
|
-
3. **Update packages:**
|
|
507
|
-
```bash
|
|
508
|
-
npm update axios react-hook-form zod
|
|
509
|
-
```
|
|
510
|
-
|
|
511
|
-
4. **Fix security issue:**
|
|
512
|
-
```bash
|
|
513
|
-
npm audit fix
|
|
514
|
-
```
|
|
515
|
-
```
|
|
516
|
-
|
|
517
|
-
---
|
|
518
|
-
|
|
519
|
-
## Configuration
|
|
520
|
-
|
|
521
|
-
```yaml
|
|
522
|
-
# proagents.config.yaml
|
|
523
|
-
|
|
524
|
-
reverse_engineering:
|
|
525
|
-
dependency_mapping:
|
|
526
|
-
enabled: true
|
|
527
|
-
|
|
528
|
-
analyze:
|
|
529
|
-
- internal_modules
|
|
530
|
-
- external_packages
|
|
531
|
-
- circular_dependencies
|
|
532
|
-
- dead_code
|
|
533
|
-
- package_health
|
|
534
|
-
|
|
535
|
-
report:
|
|
536
|
-
format: "markdown"
|
|
537
|
-
include_visualizations: true
|
|
538
|
-
include_recommendations: true
|
|
539
|
-
|
|
540
|
-
thresholds:
|
|
541
|
-
max_coupling_score: 10
|
|
542
|
-
max_circular_deps: 0
|
|
543
|
-
security_block_on: ["critical", "high"]
|
|
544
|
-
|
|
545
|
-
ignore:
|
|
546
|
-
packages:
|
|
547
|
-
- "dev-only-tool"
|
|
548
|
-
paths:
|
|
549
|
-
- "scripts/"
|
|
550
|
-
- "__tests__/"
|
|
551
|
-
```
|
|
552
|
-
|
|
553
|
-
---
|
|
554
|
-
|
|
555
|
-
## Commands
|
|
556
|
-
|
|
557
|
-
| Command | Description |
|
|
558
|
-
|---------|-------------|
|
|
559
|
-
| `pa:re-deps` | Full dependency analysis |
|
|
560
|
-
| `pa:re-deps --internal` | Internal modules only |
|
|
561
|
-
| `pa:re-deps --external` | External packages only |
|
|
562
|
-
| `pa:re-deps --circular` | Find circular dependencies |
|
|
563
|
-
| `pa:re-deps --dead` | Find dead/unused code |
|
|
564
|
-
| `pa:re-deps --security` | Security vulnerability check |
|
|
565
|
-
| `pa:re-deps --impact [file]` | Impact analysis for file |
|
|
566
|
-
| `pa:re-deps --outdated` | List outdated packages |
|
|
567
|
-
| `pa:re-deps --tree` | Show dependency tree |
|