semver-regex | Regular expression for matching semver versions | Regex library
kandi X-RAY | semver-regex Summary
kandi X-RAY | semver-regex Summary
Regular expression for matching semver versions
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of semver-regex
semver-regex Key Features
semver-regex Examples and Code Snippets
Community Discussions
Trending Discussions on semver-regex
QUESTION
I search on SO and on google a good validation regex to detect FULL NPM / other package name (package name(@)version number - all formats).
Now, before you mark this question as duplicate, I must say I searched over here and none of what I found has worked for me:
Regex to parse package name and version number from nuget package filenames
A regex for version number parsing
npm/validate-npm-package-name
Semantic versioning regex
package-name-regex
semver-regex
I also tried a couple of regex myself but none of them do the work for any edge case:
...ANSWER
Answered 2020-Nov-17 at 17:57You may try this regex:
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install semver-regex
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page