Gathering detailed insights and metrics for make-empty-dir
Gathering detailed insights and metrics for make-empty-dir
Gathering detailed insights and metrics for make-empty-dir
Gathering detailed insights and metrics for make-empty-dir
npm install make-empty-dir
Typescript
Module System
Min. Node Version
Node Version
NPM Version
92.5
Supply Chain
78.7
Quality
78
Maintenance
100
Vulnerability
100
License
JavaScript (77.07%)
TypeScript (22.93%)
Total Downloads
747,481
Last Day
636
Last Week
14,522
Last Month
68,286
Last Year
262,759
MIT License
102 Stars
440 Commits
28 Forks
4 Watchers
30 Branches
22 Contributors
Updated on Jun 13, 2025
Minified
Minified + Gzipped
Latest Version
3.0.2
Package Id
make-empty-dir@3.0.2
Unpacked Size
4.33 kB
Size
2.05 kB
File Count
5
NPM Version
10.8.1
Node Version
20.11.1
Published on
Jul 04, 2024
Cumulative downloads
Total Downloads
Last Day
-17.9%
636
Compared to previous day
Last Week
-16.3%
14,522
Compared to previous week
Last Month
47.6%
68,286
Compared to previous month
Last Year
30.8%
262,759
Compared to previous year
1
Ensures that a directory is empty
Ensures that a directory is empty. Deletes directory contents if the directory is not empty. If the directory does not exist, it is created. The directory itself is not deleted.
It works faster than emptyDir()
of fs-extra
because the contents of the directory are not read before the creation of the directory.
1<npm|yarn|pnpm> add make-empty-dir
1'use strict' 2const makeEmptyDir = require('make-empty-dir') 3 4await makeEmptyDir('dir-name') 5 6// or create the parent dir as well 7await makeEmptyDir('dir/subdir', { recursive: true })
makeEmptyDir(dir: string, [opts]): Promise<'created' | 'emptied'>
Arguments:
dir
- Path - the path of the directory.opts.recursive
- Boolean - Optional. If true, parent directories will be created.Returns:
A string is returned.
'created'
- if there was no directory'emptied'
- if there was a directory and the its contents were removed.No vulnerabilities found.
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
Found 8/30 approved changesets -- score normalized to 2
Reason
3 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 2
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Reason
15 existing vulnerabilities detected
Details
Score
Last Scanned on 2025-06-09
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More