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

stx

Package Overview
Dependencies
Maintainers
1
Versions
56
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

stx - npm Package Compare versions

Comparing version 0.5.3 to 0.5.4

45

dist/index.js

@@ -1047,2 +1047,41 @@ 'use strict';

const bindAllDataListener = (branch, persist) => {
if (!branch.listeners.allData) {
branch.listeners.allData = {};
}
branch.listeners.allData['persist'] = (type, _, item) => {
if (branch.leaves[item.id]) {
if (type === 'remove') {
persist.remove(String(item.id));
} else {
persist.store(
String(item.id),
Object.assign(
{ keyString: getString(branch.leaves[item.id].key) },
branch.leaves[item.id]
)
);
}
}
};
};
const loadLeaf = (branch, id, leaf) => {
addToStrings(leaf.key, leaf.keyString);
delete leaf.keyString;
if (leaf.val || leaf.rT) {
const rTold = getRtFromLeaves(branch, id);
if (rTold) {
delete branch.rF[rTold][id];
}
if (leaf.rT) {
addReferenceFrom(branch, id, leaf.rT);
}
}
branch.leaves[id] = leaf;
};
const cloneIds = (to, from, parent) => {

@@ -1107,4 +1146,6 @@ for (const id in from) {

return persist.start(new Leaf(branch, root), addToStrings, getString)
.then(() => persist.load())
branch.persist = persist;
return persist.start()
.then(() => persist.load((id, leaf) => loadLeaf(branch, id, leaf)))
.then(() => bindAllDataListener(branch, persist))
.then(() => setToNewBranch(branch, val, stamp))

@@ -1111,0 +1152,0 @@ };

2

package.json
{
"name": "stx",
"version": "0.5.3",
"version": "0.5.4",
"description": "a blazing fast state manager with network sync out of the box",

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

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

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