function isEmpty(...args) {
  return !args || !args.length
    ? true
    : args.some((arg) => !(arg && size(arg)) || arg.isEmpty === true)
}
Detect whether items are empty or not
@param {object} args - Item to check loaded status of. A comma seperated list
is also acceptable.
@returns {boolean} Whether or not item is empty
@example
import React from 'react'
import PropTypes from 'prop-types'
import { compose } from 'redux'
import { connect } from 'react-redux'
import { firebaseConnect, isEmpty, isLoaded } from 'react-redux-firebase'

const enhance = compose(
  firebaseConnect(['todos']),
  connect(({ firebase: { data: { todos } } }) => ({
    todos // state.firebase.data.todos from redux passed as todos prop
  }))
)

function Todos({ todos }) {
  // Message for if todos are loading
  if (!isLoaded(todos)) {
    return <span>Loading...</span>
  }

  // Message if todos are empty
  if (isEmpty(todos)) {
    return <span>No Todos Found</span>
  }

  return <todos>{JSON.stringify(todos)}</todos>
}

Todos.propTypes = {
  todos: PropTypes.object
}

export default enhance(Todos)