Created
March 31, 2022 20:29
-
-
Save Keraito/b4b354482ffeb55f0e345d9e284228d0 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function shallowEqual(objA: mixed, objB: mixed): boolean { | |
// ... | |
const keysA = Object.keys(objA); | |
const keysB = Object.keys(objB); | |
if (keysA.length !== keysB.length) { | |
return false; | |
} | |
// ... | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment