Socket
Socket
Sign inDemoInstall

junk

Package Overview
Dependencies
0
Maintainers
1
Versions
15
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 3.0.0 to 3.1.0

24

index.d.ts

@@ -9,2 +9,21 @@ declare const junk: {

Returns `true` if `filename` doesn't match a junk file.
@example
```
import {promisify} from 'util';
import * as fs from 'fs';
import junk = require('junk');
const pReaddir = promisify(fs.readdir);
(async () => {
const files = await pReaddir('some/path');
console.log(files);
//=> ['.DS_Store', 'test.jpg']
console.log(files.filter(junk.not));
//=> ['test.jpg']
})();
```
*/

@@ -17,4 +36,7 @@ not(filename: string): boolean;

readonly regex: RegExp;
// TODO: Remove this for the next major release
default: typeof junk;
};
export default junk;
export = junk;

@@ -38,2 +38,3 @@ 'use strict';

// TODO: Remove this for the next major release
exports.default = module.exports;

8

package.json
{
"name": "junk",
"version": "3.0.0",
"version": "3.1.0",
"description": "Filter out system junk files like .DS_Store and Thumbs.db",

@@ -16,3 +16,3 @@ "license": "MIT",

"scripts": {
"test": "xo && ava && tsd-check"
"test": "xo && ava && tsd"
},

@@ -39,6 +39,6 @@ "files": [

"devDependencies": {
"ava": "^1.3.1",
"tsd-check": "^0.5.0",
"ava": "^1.4.1",
"tsd": "^0.7.1",
"xo": "^0.24.0"
}
}
SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc