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

ngraph.merge

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ngraph.merge

Simple merge utility to extend objects without extra dependencies

  • 1.0.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

ngraph.merge

Simple merge utility to extend objects without extra dependencies. This utility may be useful when you want to quickly provide optional settings

build status

usage

  var merge = require('ngraph.merge');
  var options = { age: 42 };
  merge(options, { name: 'John' });
  console.log(options); // { age: 42, name: 'John'}

  merge(options, { age: 100 });
  console.log(options.age); // 42. Options already has age defined

  merge(options, {age: '100'});
  console.log(options.age); // '100'. Type mismatch. Age is overwritten

For more examples please refer to tests.

why?

I want to control dependencies chain and not pull too many external libraries into ngraph.

install

With npm do:

npm install ngraph.merge

license

MIT

Keywords

FAQs

Package last updated on 29 May 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

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