@keep-lts/defaults-deep
v0.2.5
Published
Security-maintained drop-in fork of defaults-deep. Patches CVE-2018-16486 (prototype pollution). Original API unchanged.
Maintainers
Readme
@keep-lts/defaults-deep
Security-maintained, drop-in fork of
defaults-deep.
[!IMPORTANT] Unofficial security-maintenance fork. The original
defaults-deephas no fix for CVE-2018-16486 / GHSA-pjxw-22xf-6pwc (Critical). This fork applies a minimal, tested patch and keeps the public API byte-for-byte compatible. Adopt with zero code changes via npmoverrides:{ "overrides": { "defaults-deep": "npm:@keep-lts/defaults-deep@^0.2.5" } }See SECURITY.md and CHANGELOG.md. Original functionality and attribution preserved under the MIT license.
defaults-deep

Like
extendbut recursively copies only the missing properties/values to the target object.
Install
Install with npm
$ npm i defaults-deep --saveInstall with bower
$ bower install defaults-deep --saveUsage
var defaults = require('defaults-deep');
defaults({a: {one: 'one'}}, {a: {two: 'two'}})
//=> {a: {one: 'one', two: 'two'}};Related projects
- assign-deep: Deeply assign the enumerable properties of source objects to a destination object. If a callback… more
- extend-shallow: Extend an object with the properties of additional objects. node.js/javascript util.
- merge-deep: Recursively merge values in a javascript object.
- mixin-deep: Deeply mix the properties of objects into the first object. Like merge-deep, but doesn't clone.
- omit-deep: Recursively omit the given keys from an object.
Running tests
Install dev dependencies:
$ npm i -d && npm testContributing
Pull requests and stars are always welcome. For bugs and feature requests, please create an issue
Author
Jon Schlinkert
License
Copyright © 2015 Jon Schlinkert Released under the MIT license.
This file was generated by verb-cli on May 28, 2015.
