Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

pkgs-graph

Package Overview
Dependencies
Maintainers
1
Versions
30
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pkgs-graph - npm Package Compare versions

Comparing version 1.0.0 to 1.1.0

11

lib/index.js

@@ -7,2 +7,3 @@ "use strict";

const R = require("ramda");
const npa = require("npm-package-arg");
const oneLine = commonTags.oneLine;

@@ -24,2 +25,12 @@ const highlight = chalk.yellow;

.map(depName => {
const spec = npa.resolve(depName, dependencies[depName], pkg.path);
if (spec.type === 'directory') {
const matchedPkg = R.values(pkgMap).find(pkg => pkg.path === spec.fetchSpec);
if (!matchedPkg) {
return '';
}
return createPkgSpec(matchedPkg);
}
if (spec.type !== 'version' && spec.type !== 'range')
return '';
const range = dependencies[depName];

@@ -26,0 +37,0 @@ const pkgs = R.values(pkgMap).filter(pkg => pkg.manifest.name === depName);

3

package.json
{
"name": "pkgs-graph",
"version": "1.0.0",
"version": "1.1.0",
"description": "Create a graph from an array of packages",

@@ -40,2 +40,3 @@ "main": "lib/index.js",

"find-packages": "^2.0.0",
"npm-package-arg": "^5.1.2",
"ramda": "^0.23.0",

@@ -42,0 +43,0 @@ "semver": "^5.3.0",

Sorry, the diff of this file is not supported yet

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