github.com/pingcap/tiflow@v0.0.0-20240520035814-5bf52d54e205/dm/ui/src/utils/isEmptyObject.ts (about)

     1  export const isEmptyObject = (o: any) => {
     2    return (
     3      typeof o === 'object' &&
     4      o !== null &&
     5      (Object.keys(o).length === 0 ||
     6        Object.values(o).every(
     7          i => typeof i === 'undefined' || i === null || i === ''
     8        ))
     9    )
    10  }