flow like the river
This commit is contained in:
commit
013fe673f3
42435 changed files with 5764238 additions and 0 deletions
38
VISUALIZACION/node_modules/ngraph.merge/README.md
generated
vendored
Executable file
38
VISUALIZACION/node_modules/ngraph.merge/README.md
generated
vendored
Executable file
|
|
@ -0,0 +1,38 @@
|
|||
# ngraph.merge
|
||||
|
||||
Simple merge utility to extend objects without extra dependencies. This utility
|
||||
may be useful when you want to quickly provide optional settings
|
||||
|
||||
[](http://travis-ci.org/anvaka/ngraph.merge)
|
||||
# usage
|
||||
|
||||
``` js
|
||||
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](https://github.com/anvaka/ngraph.merge/blob/master/test/merge.js).
|
||||
|
||||
# why?
|
||||
I want to control dependencies chain and not pull too many external libraries
|
||||
into ngraph.
|
||||
|
||||
# install
|
||||
|
||||
With [npm](https://npmjs.org) do:
|
||||
|
||||
```
|
||||
npm install ngraph.merge
|
||||
```
|
||||
|
||||
# license
|
||||
|
||||
MIT
|
||||
Loading…
Add table
Add a link
Reference in a new issue