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

@rimbu/deep

Package Overview
Dependencies
Maintainers
1
Versions
42
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@rimbu/deep - npm Package Compare versions

Comparing version 0.7.0 to 0.7.1

13

dist/main/patch.js

@@ -99,7 +99,14 @@ "use strict";

var itemPatch = patcher[Patch.MAP];
var result = arr.slice();
var result = undefined;
for (var i = 0; i < arr.length; i++) {
result[i] = patchSingle(arr[i], itemPatch, value, root);
var currentItem = arr[i];
var newItem = patchSingle(currentItem, itemPatch, value, root);
if (!Object.is(newItem, currentItem)) {
if (undefined === result) {
result = arr.slice();
}
result[i] = newItem;
}
}
return result;
return (result !== null && result !== void 0 ? result : arr);
}

@@ -106,0 +113,0 @@ var clone = valueIsArray ? tslib_1.__spreadArray([], tslib_1.__read(value)) : tslib_1.__assign({}, value);

@@ -73,7 +73,14 @@ import { RimbuError } from '@rimbu/base';

const itemPatch = patcher[Patch.MAP];
const result = arr.slice();
let result = undefined;
for (let i = 0; i < arr.length; i++) {
result[i] = patchSingle(arr[i], itemPatch, value, root);
const currentItem = arr[i];
const newItem = patchSingle(currentItem, itemPatch, value, root);
if (!Object.is(newItem, currentItem)) {
if (undefined === result) {
result = arr.slice();
}
result[i] = newItem;
}
}
return result;
return (result !== null && result !== void 0 ? result : arr);
}

@@ -80,0 +87,0 @@ const clone = valueIsArray ? [...value] : Object.assign({}, value);

{
"name": "@rimbu/deep",
"version": "0.7.0",
"version": "0.7.1",
"description": "Tools to use handle plain JS objects as immutable objects",

@@ -48,3 +48,3 @@ "keywords": [

"bundle:types": "tsc --p tsconfig.types.json",
"clean": "rimraf dist deno_dist",
"clean": "rimraf dist",
"format": "yarn format:base --write",

@@ -60,4 +60,4 @@ "format:base": "prettier \"{!CHANGELOG.md}|**/*.{ts,tsx,js,json,md}\"",

"dependencies": {
"@rimbu/base": "^0.6.1",
"@rimbu/common": "^0.6.1"
"@rimbu/base": "^0.6.2",
"@rimbu/common": "^0.7.0"
},

@@ -70,3 +70,3 @@ "publishConfig": {

},
"gitHead": "4990d9a30716d3a5e7117545e5a6ced2d36ae3ad"
"gitHead": "28453a94283b4f6bcdac1a07737b2bd58ece3658"
}

@@ -144,9 +144,16 @@ import { RimbuError } from '@rimbu/base';

const result = arr.slice();
let result: any[] | undefined = undefined;
for (let i = 0; i < arr.length; i++) {
result[i] = patchSingle(arr[i], itemPatch, value, root);
const currentItem = arr[i];
const newItem = patchSingle(currentItem, itemPatch, value, root);
if (!Object.is(newItem, currentItem)) {
if (undefined === result) {
result = arr.slice();
}
result[i] = newItem;
}
}
return result as any;
return (result ?? arr) as any;
}

@@ -153,0 +160,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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