New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@easyv/cli

Package Overview
Dependencies
Maintainers
11
Versions
130
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@easyv/cli - npm Package Compare versions

Comparing version 1.10.4-beta.22 to 1.10.4-beta.23

2

package.json
{
"name": "@easyv/cli",
"version": "1.10.4-beta.22",
"version": "1.10.4-beta.23",
"description": "Easy[V] component tools",

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

@@ -17,55 +17,34 @@

})
console.log(files, 'files', configPath);
if (Array.isArray(files) && files.length) {
const name = files[0].split('.')[0];
try {
let jsonFile = fs.existsSync(
path.join(configPath, name + '.json'),
);
glob(
`{*.common.assets.{json,js},subConfigs/*.common.assets.{json,js}}`,
{
cwd: configPath,
},
function (err, matches) {
console.log(err, matches);
if (err || matches.length === 0) {
// callback(
// `main.json or main.data.json cannot be found in ${configPath}`,
// );
return config;
}
matches
.map((filename) => filename.split('.')[0])
.some((name, i) => {
try {
let jsonFile = fs.existsSync(
path.join(configPath, name + '.json'),
);
if (jsonFile) {
config = JSON.parse(
fs.readFileSync(path.resolve(configPath, name + '.json')),
{ encoding: 'utf8' },
);
} else {
Object.keys(require.cache).forEach(function (key) {
if (key.includes('node_modules')) {
return;
}
delete require.cache[key];
});
config = require(path.resolve(
configPath,
name + '.js',
)).default;
}
} catch (error) {
// 不存在也很正常
if (jsonFile) {
config = JSON.parse(
fs.readFileSync(path.resolve(configPath, name + '.json')),
{ encoding: 'utf8' },
);
} else {
Object.keys(require.cache).forEach(function (key) {
if (key.includes('node_modules')) {
return;
}
delete require.cache[key];
});
})
});
config = require(path.resolve(
configPath,
name + '.js',
)).default;
}
} catch (error) {
// 不存在也很正常
}
}
console.log(files, 'files', configPath);
return config;
}
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