Socket
Socket
Sign inDemoInstall

mini-url

Package Overview
Dependencies
Maintainers
1
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mini-url - npm Package Compare versions

Comparing version 1.1.2 to 1.2.0

3

package.json
{
"name": "mini-url",
"description": "Lightweight isomorphic url parser.",
"version": "1.1.2",
"version": "1.2.0",
"author": "Dylan Piercey <pierceydylan@gmail.com>",

@@ -47,4 +47,5 @@ "browser": {

"dependencies": {
"get-loc": "^1.0.0",
"global": "^4.3.1"
}
}

@@ -12,5 +12,5 @@ 'use strict'

// Load up a fake document to handle url resolution and parsing.
var getLocation = require('get-loc')
var parts = require('./parts')
var doc = window.document.implementation.createHTMLDocument('parser')
var loc = (window.history && window.history.location) || window.location || { href: '' }
var $base = doc.head.appendChild(doc.createElement('base'))

@@ -25,3 +25,3 @@ var $a = doc.createElement('a')

var URL = function URL (path, base) {
$base.href = base || loc.href
$base.href = base || getLocation().href
$a.href = path

@@ -28,0 +28,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