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

@riotjs/dom-bindings

Package Overview
Dependencies
Maintainers
1
Versions
90
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@riotjs/dom-bindings - npm Package Compare versions

Comparing version 4.2.4 to 4.2.5

23

dist/esm.dom-bindings.js

@@ -52,10 +52,13 @@ /**

const append = (get, parent, children, start, end, before) => {
if ((end - start) < 2)
parent.insertBefore(get(children[start], 1), before);
else {
const fragment = parent.ownerDocument.createDocumentFragment();
while (start < end)
fragment.appendChild(get(children[start++], 1));
parent.insertBefore(fragment, before);
const isSelect = 'selectedIndex' in parent;
let selectedIndex = -1;
while (start < end) {
const child = get(children[start], 1);
if (isSelect && selectedIndex < 0 && child.selected)
selectedIndex = start;
parent.insertBefore(child, before);
start++;
}
if (isSelect && -1 < selectedIndex)
parent.selectedIndex = selectedIndex;
};

@@ -911,3 +914,3 @@

unmount(scope, parentScope) {
this.template.unmount(scope, parentScope);
this.template.unmount(scope, parentScope, true);

@@ -1567,3 +1570,5 @@ return this

this.el.parentNode.removeChild(this.el);
} else if (mustRemoveRoot !== null) {
}
if (mustRemoveRoot !== null) {
if (this.children) {

@@ -1570,0 +1575,0 @@ clearChildren(this.children[0].parentNode, this.children);

@@ -58,10 +58,13 @@ (function (global, factory) {

const append = (get, parent, children, start, end, before) => {
if ((end - start) < 2)
parent.insertBefore(get(children[start], 1), before);
else {
const fragment = parent.ownerDocument.createDocumentFragment();
while (start < end)
fragment.appendChild(get(children[start++], 1));
parent.insertBefore(fragment, before);
const isSelect = 'selectedIndex' in parent;
let selectedIndex = -1;
while (start < end) {
const child = get(children[start], 1);
if (isSelect && selectedIndex < 0 && child.selected)
selectedIndex = start;
parent.insertBefore(child, before);
start++;
}
if (isSelect && -1 < selectedIndex)
parent.selectedIndex = selectedIndex;
};

@@ -917,3 +920,3 @@

unmount(scope, parentScope) {
this.template.unmount(scope, parentScope);
this.template.unmount(scope, parentScope, true);

@@ -1573,3 +1576,5 @@ return this

this.el.parentNode.removeChild(this.el);
} else if (mustRemoveRoot !== null) {
}
if (mustRemoveRoot !== null) {
if (this.children) {

@@ -1576,0 +1581,0 @@ clearChildren(this.children[0].parentNode, this.children);

{
"name": "@riotjs/dom-bindings",
"version": "4.2.4",
"version": "4.2.5",
"description": "Riot.js DOM bindings",

@@ -40,4 +40,4 @@ "main": "dist/umd.dom-bindings.js",

"chai": "^4.2.0",
"coveralls": "^3.0.4",
"eslint": "^6.0.0",
"coveralls": "^3.0.5",
"eslint": "^6.1.0",
"eslint-config-riot": "^2.0.0",

@@ -47,7 +47,7 @@ "esm": "^3.2.25",

"jsdom-global": "3.0.2",
"mocha": "^6.1.4",
"mocha": "^6.2.0",
"nyc": "^14.1.1",
"rollup": "^1.16.2",
"rollup": "^1.18.0",
"rollup-plugin-alias": "^1.5.2",
"rollup-plugin-node-resolve": "^5.0.4",
"rollup-plugin-node-resolve": "^5.2.0",
"sinon": "^7.3.2",

@@ -57,4 +57,4 @@ "sinon-chai": "^3.3.0"

"dependencies": {
"domdiff": "^2.0.3"
"domdiff": "^2.0.6"
}
}

@@ -208,3 +208,3 @@ # dom-bindings

// add an event listener
{ type: expressionTypes.EVENT, evaluate(scope) { return function() { console.log('Hello There') } }}
{ type: expressionTypes.EVENT, name: 'onclick', evaluate(scope) { return function() { console.log('Hello There') } }}
```

@@ -216,3 +216,3 @@

// remove an event listener
{ type: expressionTypes.EVENT, evaluate(scope) { return null } }}
{ type: expressionTypes.EVENT, name: 'onclick', evaluate(scope) { return null } }}
```

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