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

@scandipwa/scandipwa-dev-utils

Package Overview
Dependencies
Maintainers
6
Versions
44
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@scandipwa/scandipwa-dev-utils - npm Package Compare versions

Comparing version 0.1.12 to 0.1.13

24

composer.js

@@ -9,2 +9,5 @@ /* eslint-disable guard-for-in, fp/no-let, no-console, max-len, import/no-dynamic-require, global-require, fp/no-loops, no-restricted-syntax */

// Reuse those deps to set as hight prior checking.
let rootDeps = {};
/**

@@ -17,3 +20,3 @@ * Recursively get "composer" field from all package.json,

*/
const getComposerDeps = (modulePath, context = modulePath) => {
const getComposerDeps = (modulePath, context = modulePath, isRoot = false) => {
if (visitedDeps.indexOf(modulePath) !== -1) {

@@ -28,6 +31,10 @@ return [];

scandipwa: {
composer = []
composer = {}
} = {}
} = getPackageJson(modulePath, context);
if (isRoot) {
rootDeps = composer;
}
return Object.keys(dependencies).reduce(

@@ -49,3 +56,3 @@ (acc, dependency) => acc.concat(getComposerDeps(dependency, context)),

const requestedComposerDeps = getComposerDeps(pathname);
const requestedComposerDeps = getComposerDeps(pathname, pathname, true);

@@ -59,3 +66,8 @@ // Index the composer deps from array of object entries.

if (acc[module].indexOf(version) === -1) {
if (rootDeps[module] && acc[module].indexOf(rootDeps[module]) === -1) {
acc[module].push(rootDeps[module]);
return acc;
}
if (!rootDeps[module] && acc[module].indexOf(version) === -1) {
acc[module].push(version);

@@ -133,3 +145,3 @@ }

// Validate if the version requested is present in composer + shwo notice about minimum version
// Validate if the version requested is present in composer + show notice about minimum version
if (!composerDeps[composerModule]) {

@@ -158,3 +170,3 @@ logger.error(

// if the version required is a range, take min version of it and
// validate it agains the range.
// validate it against the range.
if (!semver.satisfies(minUserDepVersion, rangeRequested)) {

@@ -161,0 +173,0 @@ logger.error(

{
"name": "@scandipwa/scandipwa-dev-utils",
"description": "Development utilities used by CSA.",
"version": "0.1.12",
"version": "0.1.13",
"dependencies": {
"@tilework/mosaic-dev-utils": "0.1.6",
"@tilework/mosaic-dev-utils": "0.2.1",
"cross-spawn": "^7.0.3",

@@ -16,3 +16,3 @@ "react-dev-utils": "^11.0.4",

},
"gitHead": "9823ca90ecd5b66327fab5b0d9d6ea0354d118c1"
"gitHead": "35d99c1121a2c16dbedc76f091665c67ec30ebff"
}
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