Gathering detailed insights and metrics for package-name-regex
Gathering detailed insights and metrics for package-name-regex
Gathering detailed insights and metrics for package-name-regex
Gathering detailed insights and metrics for package-name-regex
require-package-name
gets the package name for a require statement
scoped-regex
Regular expression for matching scoped npm package names
@types/package-name-regex
Stub TypeScript definitions entry for package-name-regex, which provides its own types definitions
parse-author
Parse an author, contributor, maintainer or other 'person' string into an object with name, email and url properties following npm conventions.
Provides a regex that can be used to test if a string is a valid NPM package name.
npm install package-name-regex
Typescript
Module System
Min. Node Version
Node Version
NPM Version
99.7
Supply Chain
93.5
Quality
83.2
Maintenance
100
Vulnerability
100
License
TypeScript (94.21%)
Shell (5.79%)
Total Downloads
0
Last Day
0
Last Week
0
Last Month
0
Last Year
0
NOASSERTION License
5 Stars
178 Commits
1 Forks
2 Watchers
3 Branches
5 Contributors
Updated on Jun 30, 2025
Latest Version
4.0.3
Package Id
package-name-regex@4.0.3
Unpacked Size
6.65 kB
Size
2.75 kB
File Count
5
NPM Version
10.9.2
Node Version
20.19.2
Published on
Jun 08, 2025
Cumulative downloads
Total Downloads
Last Day
0%
NaN
Compared to previous day
Last Week
0%
NaN
Compared to previous week
Last Month
0%
NaN
Compared to previous month
Last Year
0%
NaN
Compared to previous year
3
Provides a regex that can be used to test if a string is a valid NPM package name.
1# npm 2$ npm install package-name-regex 3 4# Yarn 5$ yarn add package-name-regex
1import packageNameRegex from 'package-name-regex' 2// Or import { packageNameRegex } from 'package-name-regex' 3 4packageNameRegex.test('some-package') // true 5packageNameRegex.test('example.com') // true 6packageNameRegex.test('@npm/thingy') // true 7 8packageNameRegex.test('crazy!') // false 9packageNameRegex.test('.start-with-period') // false 10packageNameRegex.test('@npm-zors/money!time.js') // false
Are you missing something or want to contribute? Feel free to file an issue or a pull request! ⚙️
Hey, I am Sebastian Landwehr, a freelance web developer, and I love developing web apps and open source packages. If you want to support me so that I can keep packages up to date and build more helpful tools, you can donate here:
If you want to send me a one time donation. The coffee is pretty good 😊.
Also for one time donations if you like PayPal.
Here you can support me regularly, which is great so I can steadily work on projects.
Thanks a lot for your support! ❤️
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
no dangerous workflow patterns detected
Reason
10 commit(s) and 1 issue activity found in the last 90 days -- score normalized to 9
Reason
license file detected
Details
Reason
4 existing vulnerabilities detected
Details
Reason
Found 2/25 approved changesets -- score normalized to 0
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Score
Last Scanned on 2025-07-07
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