Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/kalambet/object-augmenter
Small utility to augment one JS object by another
https://github.com/kalambet/object-augmenter
Last synced: 12 days ago
JSON representation
Small utility to augment one JS object by another
- Host: GitHub
- URL: https://github.com/kalambet/object-augmenter
- Owner: kalambet
- License: mit
- Created: 2016-01-29T15:26:18.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2016-02-01T14:03:25.000Z (about 9 years ago)
- Last Synced: 2024-12-31T22:46:57.192Z (about 1 month ago)
- Language: JavaScript
- Homepage:
- Size: 9.77 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Object Augmenter [![Build Status](https://travis-ci.org/kalambet/object-augmenter.svg?branch=master)](https://travis-ci.org/kalambet/object-augmenter)
###### Small utility to augment one JS object with anotherThe idea here that we are merging two JS objects like a trees (in depth). There are no special rules or arguments. The augmenter can contain only the fields that are needs to be updated plus extrs ones if needed.
## Installation
```
npm install object-augmenter
```## Usage
```
var augment = require('object-augmenter');var person = {
name: {
first: "John",
second: "Dough"
}
};augment(person, {name: {second: "Doe"}, dob: "01.01.1970"});
```## License
MIT