Typescript Function and Type Utils

· Bj√∂rn-Eric's Developer notes

A collection of small utility functions and utility types.
#typescript, #utils

# Check if object is empty

1/**
2 * Check if an object is empty
3 */
4export function isEmpty(obj: Object): boolean {
5  return Object.keys(obj).length === 0;
6}

Home