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

createcss

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

createcss - npm Package Compare versions

Comparing version 0.0.1 to 0.0.2

43

index.js

@@ -17,42 +17,17 @@ function Createcss () {

var mediaType
if (document.styleSheets.length > 0) {
for( i = 0; i < document.styleSheets.length; i++) {
if (document.styleSheets[i].disabled) {
continue
}
var media = document.styleSheets[i].media
mediaType = typeof media
if (mediaType == "string") {
if (media == "" || (media.indexOf("screen") != -1)) {
styleSheet = document.styleSheets[i]
}
} else if (mediaType == "object") {
if (media.mediaText == "" || (media.mediaText.indexOf("screen") != -1)) {
styleSheet = document.styleSheets[i]
}
}
var styleSheetElement = document.createElement("style")
styleSheetElement.type = "text/css"
if ( typeof styleSheet != "undefined") {
break
}
document.getElementsByTagName("head")[0].appendChild(styleSheetElement)
for( i = 0; i < document.styleSheets.length; i++) {
if (document.styleSheets[i].disabled) {
continue
}
styleSheet = document.styleSheets[i]
}
if ( typeof styleSheet == "undefined") {
var styleSheetElement = document.createElement("style")
styleSheetElement.type = "text/css"
document.getElementsByTagName("head")[0].appendChild(styleSheetElement)
for( i = 0; i < document.styleSheets.length; i++) {
if (document.styleSheets[i].disabled) {
continue
}
styleSheet = document.styleSheets[i]
}
var media = styleSheet.media
var media = styleSheet.media
mediaType = typeof media
}

@@ -59,0 +34,0 @@ if (mediaType == "string") {

{
"name": "createcss",
"version": "0.0.1",
"version": "0.0.2",
"description": "createcss =========",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -6,2 +6,4 @@ createcss

[![NPM](https://nodei.co/npm/createcss.png?global=true)](https://nodei.co/npm/createcss/)
```javascript

@@ -8,0 +10,0 @@ var createcss = require('createcss')

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