
Security News
rv Is a New Rust-Powered Ruby Version Manager Inspired by Python's uv
Ruby maintainers from Bundler and rbenv teams are building rv to bring Python uv's speed and unified tooling approach to Ruby development.
dependencies-tree-builder
Advanced tools
A package that creates a dependency tree in a future webpack bundle only by package.json.
A package that creates a dependency tree in a future webpack bundle only by package.json.
For example, you have package.json
:
{
"name": "demo-project",
"version": "1.0.0",
"dependencies": {
"@nivo/bar": "0.54.0",
"@nivo/core": "0.53.0",
"@nivo/pie": "0.54.0",
"@nivo/stream": "0.54.0"
}
}
Use this package:
const buildTreeAsync = require('dependencies-tree-builder');
const packageJson = require('./package.json');
const {
tree,
scoupe,
packageCollector,
} = await buildTreeAsync(packageJson);
tree - full dependencies tree. In the example above:
{
"fullName": "demo-project@1.0.0",
"name": "demo-project",
"version": "1.0.0",
"usage": [],
"dependencies": [
{
"fullName": "@nivo/bar@0.54.0",
"name": "@nivo/bar",
"version": "0.54.0",
"usage": [
"demo-project@1.0.0"
],
"dependencies": [
{
"fullName": "@nivo/axes@0.54.0",
"name": "@nivo/axes",
"version": "0.54.0",
"usage": [
"demo-project@1.0.0",
"@nivo/bar@0.54.0"
],
"dependencies": [
{
"fullName": "@nivo/core@0.54.0",
"name": "@nivo/core",
"version": "0.54.0",
"usage": [
"demo-project@1.0.0",
"@nivo/bar@0.54.0",
"@nivo/axes@0.54.0"
],
"dependencies": [
...
}
scoupe - aggregated tree by package name and version. In the example above:
{
"@nivo/bar": {
"0.54.0": {
"usages": [
[
"demo-project@1.0.0"
]
],
"version": "0.54.0",
"name": "@nivo/bar",
"tunable": true,
"dedupedUsages": [
[
"demo-project@1.0.0"
]
],
"countInstances": 1,
"carriers": [
"demo-project@1.0.0"
],
"popular": true,
"main": true
}
},
"@nivo/axes": {
"0.54.0": {
"usages": [
[
"demo-project@1.0.0",
"@nivo/bar@0.54.0"
]
...
}
packageCollector - wrap package-json package with cache, has methods:
npm i --save dependencies-tree-builder
Got ideas on how to make this better? Open an issue!
MIT
FAQs
A package that creates a dependency tree in a future webpack bundle only by package.json.
The npm package dependencies-tree-builder receives a total of 1 weekly downloads. As such, dependencies-tree-builder popularity was classified as not popular.
We found that dependencies-tree-builder demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Ruby maintainers from Bundler and rbenv teams are building rv to bring Python uv's speed and unified tooling approach to Ruby development.
Security News
Following last week’s supply chain attack, Nx published findings on the GitHub Actions exploit and moved npm publishing to Trusted Publishers.
Security News
AGENTS.md is a fast-growing open format giving AI coding agents a shared, predictable way to understand project setup, style, and workflows.