Socket
Socket
Sign inDemoInstall

@npmcli/arborist

Package Overview
Dependencies
Maintainers
6
Versions
192
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@npmcli/arborist - npm Package Compare versions

Comparing version 0.0.17 to 0.0.18

12

lib/arborist/build-ideal-tree.js

@@ -8,3 +8,2 @@ // mixin implementing the buildIdealTree method

const pickManifest = require('npm-pick-manifest')
const mapWorkspaces = require('@npmcli/map-workspaces')
const promiseCallLimit = require('promise-call-limit')

@@ -55,3 +54,2 @@

const _manifests = Symbol('manifests')
const _mapWorkspaces = Symbol('mapWorkspaces')
const _linkFromSpec = Symbol('linkFromSpec')

@@ -240,3 +238,2 @@ const _loadPeerSet = Symbol('loadPeerSet')

.then(tree => this[_mapWorkspaces](tree))
.then(tree => {

@@ -276,11 +273,2 @@ // null the virtual tree, because we're about to hack away at it

[_mapWorkspaces] (node) {
return mapWorkspaces({ cwd: node.path, pkg: node.package })
.then(workspaces => {
if (workspaces.size)
node.workspaces = workspaces
return node
})
}
// process the add/rm requests by modifying the root node, and the

@@ -287,0 +275,0 @@ // update.names request by queueing nodes dependent on those named.

15

lib/arborist/load-actual.js

@@ -10,2 +10,3 @@ // mix-in implementing the loadActual method

const ancestorPath = require('common-ancestor-path')
const mapWorkspaces = require('@npmcli/map-workspaces')

@@ -34,2 +35,3 @@ const Shrinkwrap = require('../shrinkwrap.js')

const _loadActualActually = Symbol('loadActualActually')
const _mapWorkspaces = Symbol('mapWorkspaces')
const _actualTreePromise = Symbol('actualTreePromise')

@@ -89,2 +91,3 @@ const _actualTree = Symbol('actualTree')

: this[_actualTreePromise] = this[_loadActual](options)
.then(tree => this[_mapWorkspaces](tree))
.then(tree => this.actualTree = tree)

@@ -310,2 +313,14 @@ }

async [_mapWorkspaces] (node) {
const workspaces = await mapWorkspaces({
cwd: node.path,
pkg: node.package
})
if (workspaces.size)
node.workspaces = workspaces
return node
}
async [_findMissingEdges] () {

@@ -312,0 +327,0 @@ // try to resolve any missing edges by walking up the directory tree,

2

package.json
{
"name": "@npmcli/arborist",
"version": "0.0.17",
"version": "0.0.18",
"description": "Manage node_modules trees",

@@ -5,0 +5,0 @@ "dependencies": {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc