Skip to content

Instantly share code, notes, and snippets.

@malerba118
Created February 16, 2019 22:07
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 malerba118/20b8bd16f6fe73568511f5c57b84a2b2 to your computer and use it in GitHub Desktop.
Save malerba118/20b8bd16f6fe73568511f5c57b84a2b2 to your computer and use it in GitHub Desktop.
react-use-database default mergeEntities customizer
// default implementation of customizer when calling db.mergeEntities(entitiesPatch)
((objValue, srcValue) => {
if (isArray(objValue) || isArray(srcValue) || isSet(objValue) || isSet(srcValue)) {
return srcValue
}
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment