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

modularload

Package Overview
Dependencies
Maintainers
1
Versions
30
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

modularload - npm Package Compare versions

Comparing version 1.0.1 to 1.0.2

23

dist/main.cjs.js

@@ -85,2 +85,3 @@ 'use strict';

this.isEntered = false;
this.isChrome = navigator.userAgent.indexOf("Chrome") != -1 ? true : false;
this.init();

@@ -223,2 +224,4 @@ }

_this3.setSvgs();
_this3.setAttributes(data);

@@ -251,2 +254,22 @@

}, {
key: "setSvgs",
value: function setSvgs() {
if (this.isChrome) {
var svgs = this.newContainer.querySelectorAll('use');
if (svgs.length) {
svgs.forEach(function (svg) {
var xhref = svg.getAttribute('xlink:href');
if (xhref) {
svg.setAttribute('xlink:href', xhref);
} else {
var href = svg.getAttribute('href');
if (href) svg.setAttribute('href', href);
}
});
}
}
}
}, {
key: "setAttributes",

@@ -253,0 +276,0 @@ value: function setAttributes(data) {

@@ -83,2 +83,3 @@ function _classCallCheck(instance, Constructor) {

this.isEntered = false;
this.isChrome = navigator.userAgent.indexOf("Chrome") != -1 ? true : false;
this.init();

@@ -221,2 +222,4 @@ }

_this3.setSvgs();
_this3.setAttributes(data);

@@ -249,2 +252,22 @@

}, {
key: "setSvgs",
value: function setSvgs() {
if (this.isChrome) {
var svgs = this.newContainer.querySelectorAll('use');
if (svgs.length) {
svgs.forEach(function (svg) {
var xhref = svg.getAttribute('xlink:href');
if (xhref) {
svg.setAttribute('xlink:href', xhref);
} else {
var href = svg.getAttribute('href');
if (href) svg.setAttribute('href', href);
}
});
}
}
}
}, {
key: "setAttributes",

@@ -251,0 +274,0 @@ value: function setAttributes(data) {

2

package.json
{
"name": "modularload",
"version": "1.0.1",
"version": "1.0.2",
"description": "Dead simple page transitions and lazy loading.",

@@ -5,0 +5,0 @@ "repository": "modularorg/modularload",

@@ -23,2 +23,4 @@ export default class {

this.isChrome = (navigator.userAgent.indexOf("Chrome") != -1) ? true : false;
this.init();

@@ -145,2 +147,3 @@ }

this.setSvgs();
this.setAttributes(data);

@@ -170,2 +173,20 @@

setSvgs() {
if (this.isChrome) {
const svgs = this.newContainer.querySelectorAll('use');
if (svgs.length) {
svgs.forEach((svg) => {
const xhref = svg.getAttribute('xlink:href');
if (xhref) {
svg.setAttribute('xlink:href', xhref);
} else {
const href = svg.getAttribute('href');
if (href) svg.setAttribute('href', href);
}
});
}
}
}
setAttributes(data) {

@@ -172,0 +193,0 @@ const title = data.getElementsByTagName('title')[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