New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@metascraper/helpers

Package Overview
Dependencies
Maintainers
1
Versions
242
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@metascraper/helpers - npm Package Compare versions

Comparing version 3.6.0 to 3.8.0

12

index.js
'use strict'
const { trim, flow, isEmpty } = require('lodash')
const condenseWhitespace = require('condense-whitespace')
const { trim, flow, isString } = require('lodash')
const isRelativeUrl = require('is-relative-url')

@@ -14,8 +14,8 @@ const { resolve: resolveUrl } = require('url')

const isUrl = (url, {relative = true} = {}) => {
if (!isString(url)) return false
if (!relative) return urlRegex().test(url)
return isRelativeUrl(url) || urlRegex().test(url)
}
const urlTest = (url, {relative = true}) => relative
? isRelativeUrl(url) || urlRegex().test(url)
: urlRegex().test(url)
const isUrl = (url, opts = {}) => !isEmpty(url) && urlTest(url, opts)
const normalizeUrl = url => sanetizeUrl(url, { stripWWW: false })

@@ -22,0 +22,0 @@

@@ -5,3 +5,3 @@ {

"homepage": "https://metascraper.js.org",
"version": "3.6.0",
"version": "3.8.0",
"main": "src/index.js",

@@ -8,0 +8,0 @@ "author": {

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