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

has-pseudo-element

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

has-pseudo-element - npm Package Compare versions

Comparing version 1.0.0 to 3.3.0

license

13

index.js

@@ -1,12 +0,15 @@

'use strict';
'use strict'
var pseudoElements = require('pseudo-elements');
var pseudoElements = require('pseudo-elements')
module.exports = function hasPseudoElement(selector) {
if (typeof selector != 'string') {
throw new TypeError('has-pseudo-element expects a string');
throw new TypeError('has-pseudo-element expects a string')
}
var pseudoElementRegex = new RegExp('::?' + pseudoElements().join('|::?'), 'ig');
return pseudoElementRegex.test(selector);
var pseudoElementRegex = new RegExp(
'::?' + pseudoElements().join('|::?'),
'ig'
)
return pseudoElementRegex.test(selector)
}

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

"author": "John Otander",
"version": "1.0.0",
"version": "3.3.0",
"main": "index.js",

@@ -29,3 +29,4 @@ "directories": {

"mocha": "*"
}
},
"gitHead": "5604528037164f4b8eb81e8a5215c433c9814407"
}
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