Skip to content

Instantly share code, notes, and snippets.

@meekg33k
Last active January 17, 2020 17:11
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 meekg33k/82c795d98ab87f422030ba72f4b08b3b to your computer and use it in GitHub Desktop.
Save meekg33k/82c795d98ab87f422030ba72f4b08b3b to your computer and use it in GitHub Desktop.
A utility function to check if an object is present
const isPresentSomeObject = (arg: SomeObjectType | undefined): boolean => {
if (arg && Object.keys(arg).length > 0) {
return true;
}
return false;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment