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

arc-object

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

arc-object - npm Package Compare versions

Comparing version 3.1.2 to 4.0.0

7

__tests__/constant.js

@@ -1,2 +0,2 @@

const ArcObject = require('../');
import ArcObject from "../index.js";

@@ -9,4 +9,2 @@ describe('ArcObject constant', () => {

testObj.A = 'B';
var hasB = false;

@@ -18,5 +16,6 @@ for(let val in testObj){

}
expect(testObj.A).toEqual('a');
expect(() => { testObj.A = 'B'; }).toThrow();
expect(hasB).toBe(false);
});
})

@@ -1,2 +0,2 @@

const ArcObject = require('../');
import ArcObject from "../index.js";

@@ -3,0 +3,0 @@ describe('ArcObject copy', () => {

@@ -1,2 +0,2 @@

const ArcObject = require('../');
import ArcObject from "../index.js";

@@ -3,0 +3,0 @@ class Test{

@@ -1,2 +0,2 @@

const ArcObject = require('../');
import ArcObject from "../index.js";

@@ -3,0 +3,0 @@ //Everybody knows objects shouldn't be used as map/array bastardizations.. but we do sometimes anyway

@@ -1,2 +0,2 @@

const ArcObject = require('../');
import ArcObject from "../index.js";

@@ -3,0 +3,0 @@ describe('ArcObject.filter',() => {

@@ -1,2 +0,2 @@

var ArcObject = require('../');
import ArcObject from "../index.js";

@@ -3,0 +3,0 @@ describe('ArcObject.forEach',() => {

@@ -1,2 +0,2 @@

var ArcObject = require('../');
import ArcObject from "../index.js";

@@ -10,7 +10,5 @@ //Test freeze methods

it('should not be able to set a new value', () => {
//Attempt overwrite
testObj.a = 'test';
expect(testObj.a).toEqual('a');
expect(() => {testObj.a = 'test'}).toThrow();
});

@@ -23,6 +21,4 @@

it('should not be able to set a new value, even on a nested object', () => {
//Attempt overwrite
testObj.b.x = 'yes';
expect(testObj.b.x).toEqual('x');
expect(() => {testObj.b.x = 'yes';}).toThrow();
});
});

@@ -1,2 +0,2 @@

var ArcObject = require('../');
import ArcObject from "../index.js";

@@ -3,0 +3,0 @@ //Test some lazy shortcut methods

@@ -1,2 +0,2 @@

const ArcObject = require('../');
import ArcObject from "../index.js";

@@ -3,0 +3,0 @@ describe('ArcObject.map',() => {

@@ -1,3 +0,3 @@

const is = require('arc-is');
const ArcObject = require('../');
import is from "arc-is";
import ArcObject from "../index.js";

@@ -4,0 +4,0 @@ //Bind ArcObject to the native object

@@ -1,2 +0,2 @@

const ArcObject = require('../');
import ArcObject from "../index.js";

@@ -3,0 +3,0 @@ describe('ArcObject.reduce',() => {

@@ -1,3 +0,3 @@

const is = require('arc-is');
const ArcObject = require('../');
import is from 'arc-is';
import ArcObject from "../index.js";

@@ -4,0 +4,0 @@ //Test native casting, toString and wrapping

@@ -1,6 +0,4 @@

"use strict";
var is = require('arc-is');
var Check = require('arc-check');
var ArcArray = require('arc-array');
const deepcopy = require('deepcopy');
import is from 'arc-is';
import ArcArray from "arc-array";
import deepcopy from "deepcopy";

@@ -282,2 +280,2 @@ class ArcObject extends Object {

module.exports = ArcObject;
export default ArcObject;
{
"name": "arc-object",
"version": "3.1.2",
"version": "4.0.0",
"description": "An object convenience subclass",
"main": "index.js",
"type": "module",
"scripts": {
"test": "jest"
"test": "node --experimental-vm-modules node_modules/jest/bin/jest.js --coverage"
},

@@ -24,10 +25,9 @@ "repository": {

"dependencies": {
"arc-array": "4.3.1",
"arc-check": "1.2.1",
"arc-is": "1.0.8",
"arc-array": "^5.0.0",
"arc-is": "^2.0.0",
"deepcopy": "^2.1.0"
},
"devDependencies": {
"jest": "^27.5.1"
"jest": "^29.2.2"
}
}
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