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

smob

Package Overview
Dependencies
Maintainers
1
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

smob - npm Package Compare versions

Comparing version 1.4.1 to 1.5.0

8

dist/type.d.ts

@@ -17,2 +17,9 @@ import type { PriorityName } from './constants';

/**
* Merge sources from left-to-right or right-to-left.
* From v2 upwards default to left independent of the option priority.
*
* default: left (aka. options.priority)
*/
arrayPriority: `${PriorityName}`;
/**
* Strategy to merge different object keys.

@@ -39,2 +46,3 @@ *

* Merge sources from left-to-right or right-to-left.
* From v2 upwards default to right.
*

@@ -41,0 +49,0 @@ * default: left

2

dist/utils/options.d.ts

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

import { PriorityName } from '../constants';
import type { Options, OptionsInput } from '../type';
export declare function buildOptions(options?: OptionsInput): Options;
export declare function togglePriority(priority: `${PriorityName}`): "left" | "right";

28

package.json
{
"name": "smob",
"version": "1.4.1",
"version": "1.5.0",
"description": "Zero dependency library to safe merge objects.",

@@ -54,19 +54,19 @@ "main": "dist/index.cjs",

"devDependencies": {
"@rollup/plugin-node-resolve": "^15.1.0",
"@swc/core": "^1.3.70",
"@swc/jest": "^0.2.26",
"@tada5hi/commitlint-config": "^1.0.2",
"@tada5hi/eslint-config-typescript": "^1.1.9",
"@tada5hi/semantic-release": "^0.1.0",
"@tada5hi/tsconfig": "^0.4.0",
"@rollup/plugin-node-resolve": "^15.2.3",
"@swc/core": "^1.4.11",
"@swc/jest": "^0.2.29",
"@tada5hi/commitlint-config": "^1.2.0",
"@tada5hi/eslint-config-typescript": "^1.2.10",
"@tada5hi/semantic-release": "^0.3.1",
"@tada5hi/tsconfig": "^0.5.1",
"@types/jest": "^29.5.3",
"@types/node": "^20.2.5",
"@types/node": "^20.10.4",
"cross-env": "^7.0.3",
"eslint": "^8.49.0",
"husky": "^8.0.3",
"eslint": "^8.57.0",
"husky": "^9.0.11",
"jest": "^29.6.1",
"rollup": "^3.23.0",
"semantic-release": "^21.0.7",
"typescript": "^5.1.6"
"rollup": "^4.13.2",
"semantic-release": "^23.0.6",
"typescript": "^5.4.3"
}
}

@@ -36,5 +36,6 @@ # SMOB 🧪

- **arrayDistinct**: `false` Remove duplicates, when merging array elements.
- **arrayPriority**: `left` (options.priority) The source aka leftmost array has by **default** the highest priority.
- **clone**: `false` Deep clone input sources.
- **inPlace**: `false` Merge sources in place.
- **priority**: `left` The source aka leftmost array/object has by **default** the highest priority.
- **priority**: `left` The source aka leftmost object has by **default** the highest priority.

@@ -41,0 +42,0 @@ The merge behaviour can be changed by creating a custom [merger](#merger).

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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