Socket
Socket
Sign inDemoInstall

parse-domain

Package Overview
Dependencies
Maintainers
1
Versions
55
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

parse-domain - npm Package Compare versions

Comparing version 1.0.0 to 1.1.0

4

CHANGELOG.md
Changelog
---------
### 1.1.0
- Fix parsing of URLs that have an @ character in the path [#13](https://github.com/peerigon/parse-domain/issues/13)
- Update tlds a27a2c83102c563978b831bd161f1fb5409376bd
### 1.0.0

@@ -5,0 +9,0 @@ - Removed private tlds from the default regexp [#4](https://github.com/peerigon/parse-domain/issues/4) [#6](https://github.com/peerigon/parse-domain/issues/6)

2

lib/parseDomain.js
"use strict";
var urlParts = /^(https?:\/\/)?(.+@)?(.+?)(:\d{2,5})?([/?].*)?$/; // 1 = protocol, 2 = auth, 3 = domain, 4 = port, 5 = path
var urlParts = /^(https?:\/\/)?([^/]*@)?(.+?)(:\d{2,5})?([/?].*)?$/; // 1 = protocol, 2 = auth, 3 = domain, 4 = port, 5 = path
var knownTlds = require("./tld.js");

@@ -5,0 +5,0 @@ var dot = /\./g;

{
"name": "parse-domain",
"version": "1.0.0",
"version": "1.1.0",
"description": "Splits an url into sub-domain, domain and effective top-level-domain",

@@ -34,7 +34,7 @@ "main": "./lib/parseDomain.js",

"chai": "^3.5.0",
"eslint": "^3.7.1",
"eslint-config-peerigon": "^6.0.0",
"eslint-plugin-jsdoc": "^2.3.1",
"mocha": "^3.1.2"
"eslint": "^3.15.0",
"eslint-config-peerigon": "^9.0.0",
"eslint-plugin-jsdoc": "^2.4.0",
"mocha": "^3.2.0"
}
}

@@ -113,3 +113,3 @@ parse-domain

// See also https://github.com/peerigon/parse-domain/issues/4
privateTlds: boolean
privateTlds: boolean - default: false
}

@@ -116,0 +116,0 @@ ```

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

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