mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-31 17:38:48 +00:00
react app
This commit is contained in:
47
react-app/node_modules/react/lib/Object.assign.js
generated
vendored
Normal file
47
react-app/node_modules/react/lib/Object.assign.js
generated
vendored
Normal file
@@ -0,0 +1,47 @@
|
||||
/**
|
||||
* Copyright 2014-2015, Facebook, Inc.
|
||||
* All rights reserved.
|
||||
*
|
||||
* This source code is licensed under the BSD-style license found in the
|
||||
* LICENSE file in the root directory of this source tree. An additional grant
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*
|
||||
* @providesModule Object.assign
|
||||
*/
|
||||
|
||||
// https://people.mozilla.org/~jorendorff/es6-draft.html#sec-object.assign
|
||||
|
||||
'use strict';
|
||||
|
||||
function assign(target, sources) {
|
||||
if (target == null) {
|
||||
throw new TypeError('Object.assign target cannot be null or undefined');
|
||||
}
|
||||
|
||||
var to = Object(target);
|
||||
var hasOwnProperty = Object.prototype.hasOwnProperty;
|
||||
|
||||
for (var nextIndex = 1; nextIndex < arguments.length; nextIndex++) {
|
||||
var nextSource = arguments[nextIndex];
|
||||
if (nextSource == null) {
|
||||
continue;
|
||||
}
|
||||
|
||||
var from = Object(nextSource);
|
||||
|
||||
// We don't currently support accessors nor proxies. Therefore this
|
||||
// copy cannot throw. If we ever supported this then we must handle
|
||||
// exceptions and side-effects. We don't support symbols so they won't
|
||||
// be transferred.
|
||||
|
||||
for (var key in from) {
|
||||
if (hasOwnProperty.call(from, key)) {
|
||||
to[key] = from[key];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return to;
|
||||
}
|
||||
|
||||
module.exports = assign;
|
Reference in New Issue
Block a user