Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

packageurl-js

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

packageurl-js - npm Package Compare versions

Comparing version 1.1.1 to 1.2.0

4

CHANGELOG.md

@@ -0,1 +1,5 @@

# 1.2.0
## Features
* Add `pub` parsing for Dart and Flutter packages (contributed by @topaztee)
# 1.1.1

@@ -2,0 +6,0 @@ ### Bug Fix

2

package.json
{
"name": "packageurl-js",
"version": "1.1.1",
"version": "1.2.0",
"description": "JavaScript library to parse and build \"purl\" aka. package URLs. This is a microlibrary implementing the purl spec at https://github.com/package-url",

@@ -5,0 +5,0 @@ "keywords": [

@@ -77,2 +77,8 @@ /*!

}
_handlePub() {
this.name = this.name.toLowerCase();
if (!/^[a-z0-9_]+$/i.test(this.name)) {
throw new Error('Invalid purl: contains an illegal character.');
}
}

@@ -85,2 +91,5 @@ toString() {

}
if (this.type === 'pub') {
this._handlePub();
}

@@ -87,0 +96,0 @@ if (this.namespace) {

@@ -327,2 +327,26 @@ [

{
"description": "checks for invalid characters",
"purl": "pkg:pub/flutter_downloader@1.0.0",
"canonical_purl": "pkg:pub/flutter_downloader@1.0.0",
"type": "pub",
"namespace": null,
"name": "flutter_downloader",
"version": "1.0.0",
"qualifiers": null,
"subpath": null,
"is_invalid": false
},
{
"description": "checks for invalid characters",
"purl": "pkg:pub/flutter--downloader@1.0.0",
"canonical_purl": "pkg:pub/flutter--downloader@1.0.0",
"type": "pub",
"namespace": null,
"name": null,
"version": null,
"qualifiers": null,
"subpath": null,
"is_invalid": true
},
{
"description": "namespace can contain special characters",

@@ -329,0 +353,0 @@ "purl": "pkg:npm/%40foo%40%3F%23/bar@1.0.0",

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc