Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

objects.assign #158

Closed
3 tasks done
jkvyff opened this issue Jan 5, 2020 · 1 comment
Closed
3 tasks done

objects.assign #158

jkvyff opened this issue Jan 5, 2020 · 1 comment
Labels
enhancement New feature or request operator

Comments

@jkvyff
Copy link
Collaborator

jkvyff commented Jan 5, 2020

Assign merges object properties from all supplied objects. If a property already exists, then it is overwritten when merged from left to right.

Checklist

  • implementation
  • tests
  • jsdoc

Details

const someObj = { hold: 44, fast: 14 };
const result = objects.assign(someObj, { hold: 25, your: 19, horses: 4 });
console.log(result);
> { hold: 25, fast: 14, your: 19, horses: 4 }

References

@evanplaice
Copy link
Member

evanplaice commented Jan 5, 2020

Added in v0.67

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request operator
Projects
None yet
Development

No branches or pull requests

2 participants