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

extend-shallow

Package Overview
Dependencies
Maintainers
1
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

extend-shallow - npm Package Compare versions

Comparing version 0.1.0 to 0.1.1

2

.verbrc.md

@@ -6,3 +6,3 @@ # {%= name %} {%= badge("fury") %}

## Install
{%= include("install") %}
{%= include("install-npm", {save: true}) %}

@@ -9,0 +9,0 @@ ## Run tests

'use strict';
// faster slice
var slice = require('array-slice');
/**

@@ -12,4 +15,2 @@ * Extend the target `obj` with the properties of other objects.

module.exports = function extend(o) {
var args = [].slice.call(arguments, 1);
if (o == null) {

@@ -19,3 +20,6 @@ return {};

var args = slice(arguments, 1);
var len = args.length;
var i = 0;
if (len === 0) {

@@ -25,4 +29,4 @@ return o;

for (var i = 0; i < len; i++) {
var obj = args[i];
while (len--) {
var obj = args[i++];

@@ -29,0 +33,0 @@ for (var key in obj) {

{
"name": "extend-shallow",
"description": "Extend javascript object A with the properties of object B.",
"version": "0.1.0",
"version": "0.1.1",
"homepage": "https://github.com/jonschlinkert/extend-shallow",

@@ -45,3 +45,6 @@ "author": {

"props"
]
],
"dependencies": {
"array-slice": "^0.2.2"
}
}

@@ -7,6 +7,6 @@ # extend-shallow [![NPM version](https://badge.fury.io/js/extend-shallow.svg)](http://badge.fury.io/js/extend-shallow)

## Install
#### Install with [npm](npmjs.org):
#### Install with [npm](npmjs.org)
```bash
npm i extend-shallow --save-dev
npm i extend-shallow --save
```

@@ -42,2 +42,2 @@

_This file was generated by [verb-cli](https://github.com/assemble/verb-cli) on October 06, 2014._
_This file was generated by [verb-cli](https://github.com/assemble/verb-cli) on October 28, 2014._

@@ -16,3 +16,9 @@ /*!

extend({a: 'b'}, {c: 'd'}).should.eql({a: 'b', c: 'd'});
extend({a: 'b', c: 'd'}, {c: 'e'}).should.eql({a: 'b', c: 'e'});
});
it('should return an empty object when args are undefined.', function () {
extend(null).should.eql({});
extend(undefined).should.eql({});
});
});
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