|
|
Ok!
|
|
|
Ok!
|
|---|---|---|---|---|
| 226 | var player = {score: 1, name: 'Jeff'};
var newPlayer = Object.assign({}, player, {score: 2});
// or var newPlayer = {...player, score: 2};
| create new object, js | 100300 | Создать новый объект из старого в Javascript |