extend-basic

extend objects in javascript

Usage no npm install needed!

<script type="module">
  import extendBasic from 'https://cdn.skypack.dev/extend-basic';
</script>

README

extend-basic

NPM version build status schoolmarm-standard-style Downloads

extend objects in javascript (shallow)

Install

Install with npm

npm i extend-basic --save

Run tests

npm test

Usage

var extend = require('extend-basic')

var a = {
  foo: 1,
  bar: 'baz',
  bam: true
}

var b = {
  bam: false,
  boo: [1, 2, 3]
}

console.log(extend(a, b)) // produces -->

{
  foo: 1,
  bar: 'baz',
  bam: false,
  boo: [1, 2, 3]
}

API

Contributing

Pull requests are welcome. For bugs and feature requests, please create an issue

Author

Keith Williams

License

Copyright (c) 2014-2015 Keith Williams
Released under the MIT license