Socket
Socket
Sign inDemoInstall

type-coverage

Package Overview
Dependencies
13
Maintainers
1
Versions
130
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.0.7 to 1.0.8

24

dist/index.js

@@ -13,2 +13,14 @@ "use strict";

}
function statAsync(file) {
return new Promise((resolve, reject) => {
fs.stat(file, (error, stats) => {
if (error) {
reject(error);
}
else {
resolve(stats);
}
});
});
}
function globAsync(pattern, ignore) {

@@ -64,3 +76,13 @@ return new Promise((resolve, reject) => {

else if (include && Array.isArray(include) && include.length > 0) {
rootNames = await globAsync(include.length === 1 ? include[0] : `{${include.join(",")}}`, exclude);
const rules = [];
for (const file of include) {
const stats = await statAsync(file);
if (stats.isDirectory()) {
rules.push(`${file.endsWith("/") ? file.substring(0, file.length - 1) : file}/**/*.{ts,tsx}`);
}
else if (stats.isFile()) {
rules.push(file);
}
}
rootNames = await globAsync(rules.length === 1 ? rules[0] : `{${rules.join(",")}}`, exclude);
}

@@ -67,0 +89,0 @@ else {

2

package.json
{
"name": "type-coverage",
"version": "1.0.7",
"version": "1.0.8",
"description": "A CLI tool to check type coverage for typescript code",

@@ -5,0 +5,0 @@ "main": "index.js",

SocketSocket SOC 2 Logo

Product

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

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc