Skip to content

Instantly share code, notes, and snippets.

@WaldoJeffers
Last active June 3, 2018 10:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save WaldoJeffers/320909acc116af0a253ed2cdd8f4248b to your computer and use it in GitHub Desktop.
Save WaldoJeffers/320909acc116af0a253ed2cdd8f4248b to your computer and use it in GitHub Desktop.
import { add, mergeWith } from 'conductor'
const mergeByAdding = mergeWith(add)
// mergeByAdding({ Alderaan: 1, Tattooine: 2 }, { Tattooine: 1 })
// == { Alderaan: 1, Tattooine: 3 }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment