replace if array of object has empty data js code example Example: express check if object is empty if(Object.keys(obj).length === 0) { }