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

boxed-immutable

Package Overview
Dependencies
Maintainers
1
Versions
29
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

boxed-immutable - npm Package Compare versions

Comparing version 0.4.0 to 0.4.2

test/array-magic.test.js

2

package.json
{
"name": "boxed-immutable",
"version": "0.4.0",
"version": "0.4.2",
"private": false,

@@ -5,0 +5,0 @@ "description": "Immutable proxy wrapper with exception free access to nested properties and auto-instantiation of intermediate containers when nested properties are defined",

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

});
test(`path_$(${path})._$ = 'prefix.'+ ${path} === prefix.${path}`, () => {

@@ -67,3 +67,3 @@ let pathVal = boxedProxy.path_$(path)('prefix.' + path);

});
test(`path_$(${path}).$_value = 'prefix.'+ ${path} === prefix.${path}`, () => {

@@ -74,3 +74,3 @@ boxedProxy.path_$(path).$_value = 'prefix.' + path;

});
test(`path_$(${path}, String.prototype.toUpperCase, undefined) === prefix.${path}`, () => {

@@ -80,3 +80,3 @@ let pathVal = boxedProxy.path_$(path, String.prototype.toUpperCase, undefined);

});
test(`$_path(${path}) === ${path}`, () => {

@@ -91,3 +91,3 @@ let pathVal = boxedProxy.$_path(path);

});
test(`$_path(${path}, String.prototype.toUpperCase, undefined) === prefix.${path}`, () => {

@@ -100,1 +100,10 @@ let pathVal = boxedProxy.$_path(path, String.prototype.toUpperCase, undefined);

test(`$_path(), returning function is not a proxy`, () => {
let vals = createBoxed({ func: () => {} });
let origVal = vals.origVal;
let boxedVal = vals.boxedVal;
let boxedProxy = vals.boxedProxy;
let pathVal = boxedProxy.$_path('func');
expect(!!isBoxedProxy(pathVal)).toBe(false);
});

@@ -5,2 +5,3 @@ # Version History

- [Next: 0.4.2](#next-042)
- [Next: 0.4.0](#next-040)

@@ -23,2 +24,10 @@ - [0.3.2](#032)

## Next: 0.4.2
* Add: `$_array` to always return a boxed-out proxy of an array value, non-array values
(including objects) will be wrapped in an array, invalid values return `[]`.
* Add: `$_object` to always return a boxed-out proxy of an object value, if value is an array
its own properties will be copied to the object, all others return `{}`.
## Next: 0.4.0

@@ -25,0 +34,0 @@

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