Function
assign (original, args) Object public
Module: | @ember/polyfills |
---|
Defined in packages/ember-utils/lib/assign.js:4
import { assign } from '@ember/polyfills';
- original
- Object
- The object to assign into
- args
- Object
- The objects to copy properties from
- returns
- Object
Copy properties from a source object to a target object.
var a = { first: 'Yehuda' }; var b = { last: 'Katz' }; var c = { company: 'Tilde Inc.' }; Ember.assign(a, b, c); // a === { first: 'Yehuda', last: 'Katz', company: 'Tilde Inc.' }, b === { last: 'Katz' }, c === { company: 'Tilde Inc.' }
© 2020 Yehuda Katz, Tom Dale and Ember.js contributors
Licensed under the MIT License.
https://api.emberjs.com/ember/2.18/functions/@ember%2Fpolyfills/assign