easy-dep-graph 1.1.2 → 1.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.
Files changed (4) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +162 -130
  3. package/bin/index.js +1128 -462
  4. package/package.json +74 -67
package/LICENSE CHANGED
@@ -1,21 +1,21 @@
1
- MIT License
2
-
3
- Copyright (c) 2023 danisss9
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
1
+ MIT License
2
+
3
+ Copyright (c) 2026 danisss9
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -1,130 +1,162 @@
1
- # Easy Dep Graph
2
-
3
- Easily see the dependency graph of your npm project!
4
-
5
- ## Table of Contents
6
-
7
- - [Easy Dep Graph](#easy-dep-graph)
8
- - [Table of Contents](#table-of-contents)
9
- - [Install](#install)
10
- - [Use](#use)
11
- - [Arguments](#arguments)
12
- - [Peer Dependencies](#peer-dependencies)
13
- - [Packages](#packages)
14
- - [Package Dependents](#package-dependents)
15
- - [Port](#port)
16
- - [No Open](#no-open)
17
- - [No Force Layout](#no-force-layout)
18
- - [Changelog](#changelog)
19
- - [FAQs](#faqs)
20
-
21
- ## Install
22
-
23
- ```cmd
24
- npm install -g easy-dep-graph
25
- ```
26
-
27
- ## Use
28
-
29
- Run the following command on the folder where you package.json is:
30
-
31
- ```cmd
32
- npx easy-dep-graph
33
- ```
34
-
35
- ## Arguments
36
-
37
- ### Peer Dependencies
38
-
39
- Display a comprehensive view of all peer dependencies required by your project's packages. This includes:
40
-
41
- - Package names and required versions
42
- - Which packages require each peer dependency
43
- - Automatic conflict detection when multiple incompatible versions are required
44
- - Installation status (showing which peer dependencies are already installed)
45
- - One-click installation for missing peer dependencies
46
-
47
- Command: `--peer-dependencies`
48
-
49
- Example:
50
-
51
- ```cmd
52
- npx easy-dep-graph --peer-dependencies
53
- ```
54
-
55
- ### Packages
56
-
57
- A list of packages to show on the graph separated by ','. (By default it shows all packages)
58
-
59
- Command: `--packages <packages names>`
60
-
61
- Example:
62
-
63
- ```cmd
64
- npx easy-dep-graph --packages open,mustache,fastify
65
- ```
66
-
67
- ### Package Dependents
68
-
69
- This option will only show on graph the packages that depend on the submited package.
70
-
71
- Command: `--package-dependents <package name>`
72
-
73
- Example:
74
-
75
- ```cmd
76
- npx easy-dep-graph --package-dependents is-docker
77
- ```
78
-
79
- ### Port
80
-
81
- The port number to be used when serving the dependency graph. (Default is 8080)
82
-
83
- Command: `--port <port number>`
84
-
85
- Example:
86
-
87
- ```cmd
88
- npx easy-dep-graph --port 8000
89
- ```
90
-
91
- ### No Open
92
-
93
- Flag to not open the browser after the depedency graph is done.
94
-
95
- Command: `--no-open`
96
-
97
- Example:
98
-
99
- ```cmd
100
- npx easy-dep-graph --no-open
101
- ```
102
-
103
- ### No Force Layout
104
-
105
- Flag to skip applying the force-directed layout algorithm to the dependency graph. When this flag is used, the graph will display nodes in their initial random positions without automatic layout optimization. This can be useful for very large graphs where the layout calculation might take too long, or when you want to manually arrange nodes.
106
-
107
- Command: `--no-force-layout`
108
-
109
- Example:
110
-
111
- ```cmd
112
- npx easy-dep-graph --no-force-layout
113
- ```
114
-
115
- ## Changelog
116
-
117
- **Version 1.1:**
118
-
119
- - Added `--peer-dependencies` flag to display all peer dependencies in your project
120
- - Interactive peer dependency viewer with one-click installation
121
- - Automatic version conflict detection for peer dependencies
122
- - Replaced vis-network with sigma.js for dependency view
123
-
124
- **Version 1.0:**
125
-
126
- - published library
127
-
128
- ## FAQs
129
-
130
- No FAQs for now. (⌐■_■)
1
+ # Easy Dep Graph
2
+
3
+ Easily see the dependency graph of your npm project!
4
+
5
+ ## Table of Contents
6
+
7
+ - [Easy Dep Graph](#easy-dep-graph)
8
+ - [Table of Contents](#table-of-contents)
9
+ - [Install](#install)
10
+ - [Use](#use)
11
+ - [Arguments](#arguments)
12
+ - [Peer Dependencies](#peer-dependencies)
13
+ - [Packages](#packages)
14
+ - [Package Dependents](#package-dependents)
15
+ - [Port](#port)
16
+ - [No Open](#no-open)
17
+ - [No Force Layout](#no-force-layout)
18
+ - [Security Scan](#security-scan)
19
+ - [Changelog](#changelog)
20
+ - [FAQs](#faqs)
21
+
22
+ ## Install
23
+
24
+ ```cmd
25
+ npm install -g easy-dep-graph
26
+ ```
27
+
28
+ ## Use
29
+
30
+ Run the following command on the folder where you package.json is:
31
+
32
+ ```cmd
33
+ npx easy-dep-graph
34
+ ```
35
+
36
+ ## Arguments
37
+
38
+ ### Peer Dependencies
39
+
40
+ Display a comprehensive view of all peer dependencies required by your project's packages. This includes:
41
+
42
+ - Package names and required versions
43
+ - Which packages require each peer dependency
44
+ - Automatic conflict detection when multiple incompatible versions are required
45
+ - Installation status (showing which peer dependencies are already installed)
46
+ - One-click installation for missing peer dependencies
47
+
48
+ Command: `--peer-dependencies`
49
+
50
+ Example:
51
+
52
+ ```cmd
53
+ npx easy-dep-graph --peer-dependencies
54
+ ```
55
+
56
+ ### Packages
57
+
58
+ A list of packages to show on the graph separated by ','. (By default it shows all packages)
59
+
60
+ Command: `--packages <packages names>`
61
+
62
+ Example:
63
+
64
+ ```cmd
65
+ npx easy-dep-graph --packages open,mustache,fastify
66
+ ```
67
+
68
+ ### Package Dependents
69
+
70
+ This option will only show on graph the packages that depend on the submited package.
71
+
72
+ Command: `--package-dependents <package name>`
73
+
74
+ Example:
75
+
76
+ ```cmd
77
+ npx easy-dep-graph --package-dependents is-docker
78
+ ```
79
+
80
+ ### Port
81
+
82
+ The port number to be used when serving the dependency graph. (Default is 8080)
83
+
84
+ Command: `--port <port number>`
85
+
86
+ Example:
87
+
88
+ ```cmd
89
+ npx easy-dep-graph --port 8000
90
+ ```
91
+
92
+ ### No Open
93
+
94
+ Flag to not open the browser after the depedency graph is done.
95
+
96
+ Command: `--no-open`
97
+
98
+ Example:
99
+
100
+ ```cmd
101
+ npx easy-dep-graph --no-open
102
+ ```
103
+
104
+ ### No Force Layout
105
+
106
+ Flag to skip applying the force-directed layout algorithm to the dependency graph. When this flag is used, the graph will display nodes in their initial random positions without automatic layout optimization. This can be useful for very large graphs where the layout calculation might take too long, or when you want to manually arrange nodes.
107
+
108
+ Command: `--no-force-layout`
109
+
110
+ Example:
111
+
112
+ ```cmd
113
+ npx easy-dep-graph --no-force-layout
114
+ ```
115
+
116
+ ### Security Scan
117
+
118
+ Scan your project's `node_modules` for known malicious, compromised, or typosquatted npm packages. This combines:
119
+
120
+ - A built-in database of known malicious packages (compromised versions of axios, ua-parser-js, event-stream, colors, faker, node-ipc, and many typosquats)
121
+ - Live vulnerability data from `npm audit`
122
+
123
+ Results are displayed in the terminal as a severity-sorted summary and as an interactive HTML report in the browser.
124
+
125
+ Command: `--security-scan`
126
+
127
+ Example:
128
+
129
+ ```cmd
130
+ npx easy-dep-graph --security-scan
131
+ ```
132
+
133
+ Combine with other flags:
134
+
135
+ ```cmd
136
+ npx easy-dep-graph --security-scan --port 3000 --no-open
137
+ ```
138
+
139
+ ## Changelog
140
+
141
+ **Version 1.2:**
142
+
143
+ - Added `--security-scan` flag to detect known malicious, compromised, and typosquatted npm packages
144
+ - Built-in database of 40+ known compromised packages versions including axios, ua-parser-js, event-stream, coa, rc, colors, faker, node-ipc, and many typosquats
145
+ - Integration with `npm audit` for live vulnerability data
146
+ - Terminal summary with color-coded severity levels
147
+ - Interactive HTML security report served in browser
148
+
149
+ **Version 1.1:**
150
+
151
+ - Added `--peer-dependencies` flag to display all peer dependencies in your project
152
+ - Interactive peer dependency viewer with one-click installation
153
+ - Automatic version conflict detection for peer dependencies
154
+ - Replaced vis-network with sigma.js for dependency view
155
+
156
+ **Version 1.0:**
157
+
158
+ - published library
159
+
160
+ ## FAQs
161
+
162
+ No FAQs for now. (⌐■_■)