@alimaandev/ripple 0.1.0 → 0.2.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.
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  <div align="center">
2
2
 
3
- <img src="assets/ripple-logo.png" alt="Ripple" width="120" />
3
+ <img src="https://raw.githubusercontent.com/alimaandev/ripple/main/assets/ripple-logo.png" alt="Ripple" width="120" />
4
4
 
5
5
  # Ripple
6
6
 
@@ -16,7 +16,9 @@ Change less. Break less. Know the blast radius of any file before you touch it.
16
16
  &nbsp;<a href="package.json"><img alt="Node.js >= 22" src="https://img.shields.io/badge/Node.js-%3E%3D22-339933?logo=nodedotjs&logoColor=white&style=for-the-badge"/></a>&nbsp;
17
17
  </p>
18
18
 
19
- <img src="assets/hero.svg" alt="Terminal output of `ripple analyze` — risk, affected files, routes, components, tests, and confidence score" title="ripple analyze" width="100%" />
19
+ <pre><code>npm install -g @alimaandev/ripple</code></pre>
20
+
21
+ <img src="https://raw.githubusercontent.com/alimaandev/ripple/main/assets/hero.svg" alt="Terminal output of `ripple analyze` — risk, affected files, routes, components, tests, and confidence score" title="ripple analyze" width="100%" />
20
22
 
21
23
  </div>
22
24
 
@@ -42,13 +44,12 @@ exactly how a change propagates through your codebase:
42
44
  ```text
43
45
  $ ripple analyze src/authentication/login.ts
44
46
 
45
- Risk MEDIUM
46
- Affected Files 7 files
47
- API Routes 4
48
- Components 2
49
- Tests 1
50
- Max Depth 2
51
- Confidence 100%
47
+ File src/authentication/login.ts
48
+ Risk MEDIUM · 34.7/100 ███░░░░░░░
49
+ Impact 4 routes · 2 components · 1 test
50
+ Affected 7 files
51
+ Max depth 2
52
+ Confidence 100%
52
53
  ```
53
54
 
54
55
  No black box.
@@ -92,7 +93,7 @@ Everything below is real output against a shipped example project in `tests/fixt
92
93
  ```bash
93
94
  npm install -g @alimaandev/ripple
94
95
 
95
- ripple version # → 0.1.0
96
+ ripple version # → 0.1.1
96
97
  ```
97
98
 
98
99
  Or install from source:
@@ -115,30 +116,32 @@ ripple analyze src/authentication/login.ts
115
116
  Expected output:
116
117
 
117
118
  ```text
118
- 🌊 Ripple Analysis
119
-
120
- File src/authentication/login.ts
121
- Risk MEDIUM
122
- Affected Files 7 files
123
- Components 2
124
- API Routes 4
125
- Tests 1
126
- Utilities 0
127
- Max Depth 2
128
- Confidence 100%
129
-
130
- Top Impact
131
- • Dashboard (2)
132
- • Admin (1)
133
- • Index TS (1)
134
-
135
- Circular Dependencies
136
- ⭕ src/circular/a.ts → src/circular/c.ts → src/circular/b.ts → src/circular/a.ts
137
-
138
- Affected Files (7)
139
- ├─ src/admin/page.tsx (depth 1)
140
- ├─ src/dashboard/page.tsx (depth 1)
141
- └─ src/main.ts (depth 2)
119
+ ╭ ripple ────────────────────────────╮
120
+ │ ❯ impact analysis · v0.2.0 │
121
+ ╰────────────────────────────────────╯
122
+
123
+ File src/authentication/login.ts
124
+ Risk MEDIUM · 34.7/100 ███░░░░░░░
125
+ Impact 4 routes · 2 components · 1 test
126
+ Affected 7 files
127
+ Max depth 2
128
+ Confidence 100%
129
+
130
+ ────────────────────────────────────
131
+ Top impact
132
+ ● Dashboard (2)
133
+ ● Admin (1)
134
+ ● Index TS (1)
135
+
136
+ ────────────────────────────────────
137
+ Circular dependencies
138
+ ◯ src/circular/a.ts → src/circular/c.ts → src/circular/b.ts → src/circular/a.ts
139
+
140
+ ────────────────────────────────────
141
+ Affected files (7)
142
+ ├─ src/admin/page.tsx · depth 1
143
+ ├─ src/dashboard/page.tsx · depth 1
144
+ └─ src/main.ts · depth 2
142
145
  ```
143
146
 
144
147
  ### See more of the project
@@ -151,7 +154,9 @@ ripple graph
151
154
  ```
152
155
 
153
156
  ```text
154
- 🌊 Dependency Graph
157
+ ╭ ripple ────────────────────────────╮
158
+ │ ❯ dependency graph · v0.2.0 │
159
+ ╰────────────────────────────────────╯
155
160
 
156
161
  Files 25
157
162
  Edges 28
@@ -159,8 +164,9 @@ External 4
159
164
  Unresolved 0
160
165
  Circular groups 1
161
166
 
162
- Circular Dependencies
163
- ⭕ src/circular/a.ts → src/circular/c.ts → src/circular/b.ts → src/circular/a.ts
167
+ ────────────────────────────────────
168
+ Circular dependencies
169
+ ◯ src/circular/a.ts → src/circular/c.ts → src/circular/b.ts → src/circular/a.ts
164
170
  ```
165
171
 
166
172
  Point it at a file to see its dependency tree — forwards (what it imports)
@@ -294,7 +300,7 @@ That yields a score from 0–100 and a level at thresholds 30, 55, 80 — the
294
300
  same colors the CLI prints on your terminal:
295
301
 
296
302
  <p align="center">
297
- <img src="assets/risk-levels.svg" alt="Risk levels: LOW, MEDIUM, HIGH, CRITICAL" title="Risk levels" width="440" />
303
+ <img src="https://raw.githubusercontent.com/alimaandev/ripple/main/assets/risk-levels.svg" alt="Risk levels: LOW, MEDIUM, HIGH, CRITICAL" title="Risk levels" width="440" />
298
304
  </p>
299
305
 
300
306
  Confidence (0–100) is separate — how trustworthy the analysis is. It drops
@@ -448,6 +454,13 @@ pnpm run build # tsup
448
454
  Architecture and design decisions live in [docs/architecture.md](docs/architecture.md).
449
455
  Before contributing, read [CONTRIBUTING.md](CONTRIBUTING.md).
450
456
 
457
+ ## Get started
458
+
459
+ ```bash
460
+ npm install -g @alimaandev/ripple
461
+ ripple analyze src/your-file.ts --json | jq -r .risk.level # MEDIUM, HIGH, ...
462
+ ```
463
+
451
464
  ## License
452
465
 
453
466
  MIT — see [LICENSE](LICENSE).
package/dist/bin.d.ts ADDED
@@ -0,0 +1,2 @@
1
+
2
+ export { }