Object spread vs. Object.assign
This isn’t necessarily exhaustive. Spread syntax options = {…optionsDefault, …options}; Advantages: If authoring code for execution in environments without native support, you may be able to just compile this syntax (as opposed to using a polyfill). (With Babel, for example.) Less verbose. Disadvantages: When this answer was originally written, this was a proposal, not standardized. … Read more