Installations
npm install filenamify-url
Developer Guide
Typescript
Yes
Module System
ESM
Min. Node Version
^12.20.0 || ^14.13.1 || >=16.0.0
Node Version
20.9.0
NPM Version
9.2.0
Score
99.3
Supply Chain
74.9
Quality
75.5
Maintenance
100
Vulnerability
100
License
Releases
Contributors
Unable to fetch Contributors
Languages
JavaScript (85.54%)
TypeScript (14.46%)
Developer
sindresorhus
Download Statistics
Total Downloads
40,315,864
Last Day
18,173
Last Week
73,779
Last Month
283,736
Last Year
4,105,060
GitHub Statistics
79 Stars
23 Commits
7 Forks
7 Watching
1 Branches
5 Contributors
Bundle Size
5.07 kB
Minified
2.04 kB
Minified + Gzipped
Sponsor this package
Package Meta Information
Latest Version
3.1.0
Package Id
filenamify-url@3.1.0
Unpacked Size
3.82 kB
Size
1.77 kB
File Count
5
NPM Version
9.2.0
Node Version
20.9.0
Publised On
01 Dec 2023
Total Downloads
Cumulative downloads
Total Downloads
40,315,864
Last day
30.3%
18,173
Compared to previous day
Last week
-3.5%
73,779
Compared to previous week
Last month
-35.8%
283,736
Compared to previous month
Last year
-37.1%
4,105,060
Compared to previous year
Daily Downloads
Weekly Downloads
Monthly Downloads
Yearly Downloads
Dependencies
2
filenamify-url
Convert a URL to a valid filename
Install
1npm install filenamify-url
Usage
1import filenamifyUrl from 'filenamify-url';
2
3filenamifyUrl('http://sindresorhus.com/foo?bar=baz');
4//=> 'sindresorhus.com!foo!bar=baz'
5
6filenamifyUrl('http://sindresorhus.com/foo', {replacement: '🐴'});
7//=> 'sindresorhus.com🐴foo'
8
9filenamifyUrl(new URL('http://sindresorhus.com'));
10//=> 'sindresorhus.com'
API
filenamifyUrl(url, options?)
Accepts a URL and returns a valid filename.
url
Type: string | URL
A URL to convert to a valid filename.
options
Type: object
See the filenamify
options.
Related
- filenamify-cli - CLI for this module
- filenamify - Convert a string to a valid safe filename
- slugify - Slugify a string
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
security policy file detected
Details
- Info: security policy file detected: .github/security.md:1
- Info: Found linked content: .github/security.md:1
- Info: Found disclosure, vulnerability, and/or timelines in security policy: .github/security.md:1
- Info: Found text in security policy: .github/security.md:1
Reason
no dangerous workflow patterns detected
Reason
0 existing vulnerabilities detected
Reason
license file detected
Details
- Info: project has a license file: license:0
- Info: FSF or OSI recognized license: MIT License: license:0
Reason
Found 5/23 approved changesets -- score normalized to 2
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/main.yml:15: update your workflow using https://app.stepsecurity.io/secureworkflow/sindresorhus/filenamify-url/main.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/main.yml:16: update your workflow using https://app.stepsecurity.io/secureworkflow/sindresorhus/filenamify-url/main.yml/main?enable=pin
- Warn: npmCommand not pinned by hash: .github/workflows/main.yml:20
- Info: 0 out of 2 GitHub-owned GitHubAction dependencies pinned
- Info: 0 out of 1 npmCommand dependencies pinned
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
detected GitHub workflow tokens with excessive permissions
Details
- Warn: no topLevel permission defined: .github/workflows/main.yml:1
- Info: no jobLevel write permissions found
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
project is not fuzzed
Details
- Warn: no fuzzer integrations found
Reason
branch protection not enabled on development/release branches
Details
- Warn: branch protection not enabled for branch 'main'
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
- Warn: 0 commits out of 5 are checked with a SAST tool
Score
4.2
/10
Last Scanned on 2025-01-06
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