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

@domql/state

Package Overview
Dependencies
Maintainers
3
Versions
123
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@domql/state - npm Package Compare versions

Comparing version 2.3.141 to 2.3.144

LICENSE

5

createState.js

@@ -30,3 +30,6 @@ 'use strict'

if (skipApplyMethods) {
state.parent = element.parent.state
if (element.parent && element.parent.state)
element.state.parent = element.parent.state
else
element.state.parent = element.state // self loop
return element.state

@@ -33,0 +36,0 @@ }

9

dist/cjs/createState.js

@@ -31,3 +31,3 @@ "use strict";

const createState = function(element, parent, options) {
const skip = options && options.skip ? options.skip : false;
const skipApplyMethods = Boolean(options == null ? void 0 : options.skipApplyMethods);
const objectizeState = checkForTypes(element);

@@ -48,4 +48,9 @@ if (objectizeState === false)

element.state = dependentState;
if (skip)
if (skipApplyMethods) {
if (element.parent && element.parent.state)
element.state.parent = element.parent.state;
else
element.state.parent = element.state;
return element.state;
}
applyMethods(element);

@@ -52,0 +57,0 @@ (0, import_event.triggerEventOn)("stateCreated", element);

@@ -44,3 +44,3 @@ "use strict";

};
const getChildStateInKey = (stateKey, parentState, options) => {
const getChildStateInKey = (stateKey, parentState, options = {}) => {
const arr = stateKey.split("/");

@@ -47,0 +47,0 @@ const arrLength = arr.length - 1;

@@ -104,3 +104,3 @@ "use strict";

});
const hasNotUpdated = !options.preventUpdate || !options.preventHoistElementUpdate;
const hasNotUpdated = options.preventUpdate !== true || !options.preventHoistElementUpdate;
if (!options.preventStateUpdateListener && hasNotUpdated) {

@@ -121,3 +121,3 @@ (0, import_event.triggerEventOnUpdate)("stateUpdated", obj, element, options);

const element = state.__element;
if (!options.preventUpdate) {
if (options.preventUpdate !== true) {
element.update({}, {

@@ -124,0 +124,0 @@ ...options,

{
"name": "@domql/state",
"version": "2.3.141",
"version": "2.3.144",
"license": "MIT",

@@ -29,3 +29,3 @@ "type": "module",

},
"gitHead": "c867d7db9e2450d67e97a15ffc7b61692713c234"
"gitHead": "9204bcbe3bb5a7f42c5172b3d1b174a032311d49"
}
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