Home
Docs
GitHub
Pricing
Blog
Log In

Run Sandworm Audit for your App

Get started
Hold on, we're currently generating a fresh version of this report
Generated on Apr 15, 2024 via pnpm

object.assign 4.1.0

ES6 spec-compliant Object.assign shim. From https://github.com/es-shims/es6-shim
Package summary
Share
0
issues
1
license
13
MIT
Package created
14 Mar 2014
Version published
21 Dec 2017
Maintainers
1
Total deps
13
Direct deps
4
License
MIT

Issues

0
This package has no issues

Licenses

MIT License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
sublicense
private-use
Cannot
hold-liable
Must
include-copyright
include-license
13 Packages, Including:
define-data-property@1.1.4
define-properties@1.2.1
es-define-property@1.0.0
es-errors@1.3.0
function-bind@1.1.2
get-intrinsic@1.2.4
gopd@1.0.1
has-property-descriptors@1.0.2
has-proto@1.0.3
has-symbols@1.0.3
hasown@2.0.2
object-keys@1.1.1
object.assign@4.1.0
Disclaimer

This deed highlights only some of the key features and terms of the actual license. It is not a license and has no legal value. You should carefully review all of the terms and conditions of the actual license before using the licensed material.

Sandworm is not a law firm and does not provide legal services. Distributing, displaying, or linking to this deed or the license that it summarizes does not create a lawyer-client or any other relationship.

Direct Dependencies

4
All Dependencies CSV
β“˜ This is a list of object.assign 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities
define-properties1.2.15.08 kBMIT
prod
function-bind1.1.29.57 kBMIT
prod
has-symbols1.0.36.9 kBMIT
prod
object-keys1.1.17.5 kBMIT
prod

Visualizations

Frequently Asked Questions

What does object.assign do?

Object.assign is an ES6 spec-compliant npm package that provides a 'shim' for the Object.assign method in JavaScript. A shim is a library that brings new API to an older environment. Thus, if the Object.assign method is unavailable, invoking object.assign's "shim" method can provide the functionality. The package implements the es-shim API interface and works in an ES3-supported environment and also in an ES6 environment with Symbol.

How do you use object.assign?

Using object.assign in your code is simple and straightforward. It's included into your project via the require function. You can obtain the polyfill using either one of the following lines of code in Node.js

var assign = require('object.assign').getPolyfill();
var assign = require('object.assign/polyfill')();

You can then apply 'assign' onto your target object with one or multiple source objects:

var target = { a: true };
var source1 = { b: true };
var source2 = { c: true };
var sourceN = { n: true };

assign(target, source1, source2, sourceN);

Upon execution, 'target' will have attributes of all the source objects. In case of attribute conflicts, the value from the latest source object will be kept.

Where are the object.assign docs?

The documentation for object.assign can be found within its README file at the GitHub repository object.assign. This includes detailed usage examples and function behaviors for various scenarios.